-
Notifications
You must be signed in to change notification settings - Fork 24
/
Makefile
140 lines (111 loc) · 4.22 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
#### Variables ####
export ROOT_DIR ?= $(PWD)
export AETHER_ROOT_DIR ?= $(ROOT_DIR)
export SDRAN_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/sdran
export 5GC_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/5gc
export 4GC_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/4gc
export AMP_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/amp
export GNBSIM_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/gnbsim
export OAI_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/oai
export SRSRAN_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/srsran
export UERANSIM_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/ueransim
export K8S_ROOT_DIR ?= $(AETHER_ROOT_DIR)/deps/k8s
export ANSIBLE_NAME ?= ansible-aether
export ANSIBLE_CONFIG ?= $(AETHER_ROOT_DIR)/ansible.cfg
export HOSTS_INI_FILE ?= $(AETHER_ROOT_DIR)/hosts.ini
export EXTRA_VARS ?= "@$(AETHER_ROOT_DIR)/vars/main.yml"
#### Start Ansible docker (no longer supported) ####
ansible:
export ANSIBLE_NAME=$(ANSIBLE_NAME); \
sh $(AETHER_ROOT_DIR)/scripts/ansible ssh-agent bash
#### Validate Ansible Configuration ####
aether-pingall:
echo $(AETHER_ROOT_DIR)
ansible-playbook -i $(HOSTS_INI_FILE) $(AETHER_ROOT_DIR)/pingall.yml \
--extra-vars "ROOT_DIR=$(ROOT_DIR)" --extra-vars $(EXTRA_VARS)
#### Provision AETHER Components for 5G ####
aether-k8s-install: k8s-install
aether-k8s-uninstall: k8s-uninstall
aether-5gc-install: 5gc-install
aether-5gc-uninstall: 5gc-uninstall
aether-gnbsim-install: gnbsim-install
aether-gnbsim-uninstall: gnbsim-uninstall
aether-amp-install: amp-install
aether-amp-uninstall: amp-uninstall
aether-sdran-install: sdran-install
aether-sdran-uninstall: sdran-uninstall
aether-ueransim-install: ueransim-install
aether-ueransim-uninstall: ueransim-uninstall
aether-oai-gnb-install: oai-gnb-install
aether-oai-gnb-uninstall: oai-gnb-uninstall
aether-oai-uesim-start: oai-uesim-start
aether-oai-uesim-stop: oai-uesim-stop
aether-srsran-gnb-install: srsran-gnb-install
aether-srsran-gnb-uninstall: srsran-gnb-uninstall
aether-srsran-uesim-start: srsran-uesim-start
aether-srsran-uesim-stop: srsran-uesim-stop
#### Shortcut for QuickStart Only ####
aether-install: k8s-install 5gc-install gnbsim-install amp-install
aether-uninstall: monitor-uninstall roc-uninstall gnbsim-uninstall 5gc-uninstall k8s-uninstall
#### Provision AETHER for 4G ####
#### 4G/5G share router role ####
aether-4gc-install: 4gc-core-install 5gc-router-install
aether-4gc-uninstall: 4gc-core-uninstall 5gc-router-uninstall
#### Other Useful Targets ####
aether-resetcore: 5gc-core-uninstall 5gc-core-install
aether-reset4gcore: 4gc-core-uninstall 4gc-core-install
aether-gnbsim-run: gnbsim-simulator-run
aether-add-upfs: 5gc-upf-install
aether-remove-upfs: 5gc-upf-uninstall
aether-ueransim-run: ueransim-run
# Rules:
# amp-install: roc-install roc-load monitor-install monitor-load
# amp-uninstall: monitor-uninstall roc-uninstall
# 5gc-install: 5gc-router-install 5gc-core-install
# 5gc-uninstall: 5gc-core-uninstall 5gc-router-uninstall
## run gnbsim-docker-install before running setup
# gnbsim-install: gnbsim-docker-router-install gnbsim-docker-start
# gnbsim-uninstall: gnbsim-docker-stop gnbsim-docker-router-uninstall
### Provision k8s ####
# k8s-install
# k8s-uninstall
### Provision router ####
# 5gc-router-install
# 5gc-router-uninstall
### Provision core ####
# 5gc-core-install
# 5gc-core-uninstall
# 5gc-core-reset
### Provision AMP ####
# amp-install: k8s-install roc-install roc-load monitor-install monitor-load
# amp-uninstall: monitor-uninstall roc-uninstall k8s-uninstall
### Provision and load ROC ###
# roc-install
# roc-load
# roc-uninstall
### Provision and load Monitoring ###
# monitor-install
# monitor-load
# monitor-uninstall
### Provision and run gnbsim ###
# gnbsim-docker-install
# gnbsim-docker-uninstall
# gnbsim-docker-router-install
# gnbsim-docker-router-uninstall
# gnbsim-docker-start
# gnbsim-docker-stop
# gnbsim-simulator-start
### Provision and run ueransim ###
# ueransim-install
# ueransim-run
# ueransim-uninstall
#include at the end so rules are not overwritten
include $(K8S_ROOT_DIR)/Makefile
include $(GNBSIM_ROOT_DIR)/Makefile
include $(OAI_ROOT_DIR)/Makefile
include $(SRSRAN_ROOT_DIR)/Makefile
include $(5GC_ROOT_DIR)/Makefile
include $(4GC_ROOT_DIR)/Makefile
include $(AMP_ROOT_DIR)/Makefile
include $(SDRAN_ROOT_DIR)/Makefile
include $(UERANSIM_ROOT_DIR)/Makefile