forked from opencord/cord
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
454 lines (343 loc) · 16 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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
# CORD Master Makefile
# Timestamp for log files
TS := $(shell date +'%Y%m%dT%H%M%SZ')
# Source path
BUILD ?= .
CORD ?= ..
PI ?= $(BUILD)/platform-install
KUBESPRAY ?= $(BUILD)/kubespray
MAAS ?= $(BUILD)/maas
ONOS_APPS ?= $(CORD)/onos-apps
# Configuration paths
ifdef PODCONFIG_PATH
USECASE := $(shell grep cord_profile: $(PODCONFIG_PATH) | awk '{print $$2}' | awk -F '-' '{print $$1}')
else ifdef PODCONFIG
USECASE := $(shell echo $(PODCONFIG) | awk -F '-' '{print $$1}')
else
USECASE = invalid
endif
PROFILE_D ?= $(CORD)/orchestration/profiles/$(USECASE)
PODCONFIG_PATH ?= $(PROFILE_D)/podconfig/$(PODCONFIG)
SCENARIOS_D ?= $(BUILD)/scenarios
GENCONFIG_D ?= $(BUILD)/genconfig
CONFIG_CORD_PROFILE_DIR ?= $(CORD)/../cord_profile
# Milestones/logs paths
M ?= $(BUILD)/milestones
LOGS ?= $(BUILD)/logs
PREP_MS ?= $(M)/prereqs-check $(M)/build-local-bootstrap $(M)/ciab-ovs $(M)/vagrant-up $(M)/vagrant-ssh-install $(M)/copy-cord $(M)/cord-config $(M)/copy-config $(M)/prep-buildnode $(M)/prep-headnode $(M)/deploy-elasticstack $(M)/prep-computenode
KS_MS ?= $(M)/prep-kubespray $(M)/deploy-kubespray $(M)/finish-kubespray $(M)/install-kubernetes-tools $(M)/start-xos-helm
MAAS_MS ?= $(M)/build-maas-images $(M)/maas-prime $(M)/publish-maas-images $(M)/deploy-maas
OPENSTACK_MS ?= $(M)/glance-images $(M)/deploy-openstack $(M)/deploy-computenode $(M)/onboard-openstack
XOS_MS ?= $(M)/docker-images $(M)/publish-docker-images $(M)/start-xos $(M)/onboard-profile
ONOS_MS ?= $(M)/build-onos-apps $(M)/publish-onos-apps $(M)/deploy-onos $(M)/deploy-mavenrepo
POST_INSTALL_MS ?= $(M)/setup-automation $(M)/setup-ciab-pcu $(M)/compute1-up $(M)/compute2-up $(M)/compute3-up
LOCAL_MILESTONES ?= $(M)/local-cord-config $(M)/local-docker-images $(M)/local-start-xos $(M)/local-onboard-profile
ALL_MILESTONES ?= $(PREP_MS) $(KS_MS) $(MAAS_MS) $(OPENSTACK_MS) $(XOS_MS) $(ONOS_MS) $(POST_INSTALL_MS) $(LOCAL_MILESTONES)
# Configuration files
MASTER_CONFIG ?= $(GENCONFIG_D)/config.yml
MAKEFILE_CONFIG ?= $(GENCONFIG_D)/config.mk
INVENTORY ?= $(GENCONFIG_D)/inventory.ini
PROFILE_NAME_F ?= $(GENCONFIG_D)/cord_profile
SCENARIO_NAME_F ?= $(GENCONFIG_D)/cord_scenario
CONFIG_FILES = $(MASTER_CONFIG) $(MAKEFILE_CONFIG) $(INVENTORY) $(PROFILE_NAME_F) $(SCENARIO_NAME_F)
include $(MAKEFILE_CONFIG)
# Set using files from genconfig
SCENARIO = $(shell cat $(SCENARIO_NAME_F))
PROFILE = $(shell cat $(PROFILE_NAME_F))
# Host names for SSH commands
BUILDNODE ?= head1
HEADNODE ?= ${BUILDNODE}
# Vagrant config
VAGRANT_PROVIDER ?= libvirt
VAGRANT_VMS ?= $(HEADNODE)
VAGRANT_SWITCHES ?= leaf1
VAGRANT_CWD ?= $(SCENARIOS_D)/$(SCENARIO)/
# Virsh config
VIRSH_CORDDEV_DOMAIN ?= cord_corddev
# Ansible args, for verbosity and other runtime parameters
ANSIBLE_ARGS ?=
EXTRA_VARS ?= --extra-vars "@/opt/cord_profile/genconfig/config.yml"
# Commands
SHELL = bash -o pipefail
VAGRANT ?= VAGRANT_CWD=$(VAGRANT_CWD) vagrant
ANSIBLE ?= ansible -i $(INVENTORY)
ANSIBLE_PB ?= ansible-playbook $(ANSIBLE_ARGS) -i $(INVENTORY) --extra-vars @$(MASTER_CONFIG)
ANSIBLE_PB_KS ?= ANSIBLE_CONFIG=../ansible.cfg ansible-playbook $(ANSIBLE_ARGS) -b -i inventory/cord/hosts.ini --extra-vars @../$(MASTER_CONFIG)
ANSIBLE_PB_LOCAL ?= ansible-playbook $(ANSIBLE_ARGS) -i $(PI)/inventory/head-localhost $(EXTRA_VARS)
ANSIBLE_PB_MAAS ?= ansible-playbook $(ANSIBLE_ARGS) -i /etc/maas/ansible/pod-inventory $(EXTRA_VARS)
IMAGEBUILDER ?= python $(BUILD)/scripts/imagebuilder.py
LOGCMD ?= 2>&1 | tee -a $(abspath $(LOGS)/$(TS)_$(@F))
SSH_HEAD ?= ssh $(HEADNODE)
SSH_BUILD ?= ssh $(BUILDNODE)
# default target, prints help
.DEFAULT: help
help:
@echo "Please specify a target (config, build, ...)"
# Config file generation
config: $(CONFIG_FILES)
@echo ""
@echo "CORD is configured with profile: '$(PROFILE)', scenario: '$(SCENARIO)'"
@echo "Run 'make -j4 build' to continue."
$(CONFIG_FILES):
@test -e "$(PODCONFIG_PATH)" || { echo ""; echo "PODCONFIG file $(PODCONFIG_PATH) doesn't exist!" ; echo "*** Specify a valid CORD config file using PODCONFIG or PODCONFIG_PATH ***"; echo ""; exit 1; }
ansible-playbook $(ANSIBLE_ARGS) -i 'localhost,' --extra-vars="cord_podconfig='$(PODCONFIG_PATH)' genconfig_dir='$(GENCONFIG_D)' scenarios_dir='$(SCENARIOS_D)' platform_install_dir='$(PI)' cord_profile_src_dir='$(PROFILE_D)' " $(BUILD)/ansible/genconfig.yml $(LOGCMD)
printconfig:
@echo "Scenario: '$(SCENARIO)'"
@echo "Profile: '$(PROFILE)'"
# == BUILD TARGET == #
# This is entirely determined by the podconfig/scenario, and should generally
# be set to only one value - everything else should be a dependency
build: $(BUILD_TARGETS)
@echo "make build finished sucessfully"
# Utility targets
ansible-ping:
$(ANSIBLE) -m ping all $(LOGCMD)
ansible-setup:
$(ANSIBLE) -m setup all $(LOGCMD)
clean-images:
rm -f $(M)/docker-images $(M)/local-docker-images $(M)/copy-cord $(M)/build-maas-images $(M)/build-onos-apps $(M)/publish-maas-images $(M)/publish-docker-images $(M)/publish-onos-apps
clean-genconfig:
rm -f $(CONFIG_FILES)
clean-profile:
rm -rf $(CONFIG_CORD_PROFILE_DIR)/*
rm -f $(M)/cord-config $(M)/copy-config $(M)/onboard-profile $(M)/local-onboard-profile $(M)/onboard-openstack $(M)/refresh-fabric
clean-all: virsh-domain-destroy vagrant-destroy clean-profile clean-genconfig
rm -f $(ALL_MILESTONES)
clean-onos:
$(ANSIBLE_PB) $(PI)/teardown-onos-playbook.yml $(LOGCMD)
rm -f $(M)/deploy-onos $(M)/onos-debug
clean-openstack:
$(SSH_HEAD) "/opt/cord/build/platform-install/scripts/clean_openstack.sh" $(LOGCMD)
rm -f $(M)/onboard-openstack
clean-kubespray:
rm -f $(KS_MS)
rm -rf $(KUBESPRAY)
# prereqs append the milestones dir to the front, but diag targets can be run multiple times
$(M)/collect-diag: | collect-diag
$(M)/collect-diag-maas: | collect-diag-maas
collect-diag:
$(ANSIBLE_PB) $(PI)/collect-diag-playbook.yml $(LOGCMD)
collect-diag-maas:
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_MAAS) --private-key ~/.ssh/cord_rsa $(PI)/collect-diag-playbook.yml" $(LOGCMD)
compute-node-refresh:
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_MAAS) --private-key ~/.ssh/cord_rsa $(PI)/compute-node-refresh-playbook.yml" $(LOGCMD)
vagrant-destroy:
$(VAGRANT) destroy -f $(LOGCMD) || true
rm -f $(M)/vagrant-up $(M)/vagrant-ssh-install $(VAGRANT_SSH_CONF)
virsh-domain-destroy:
virsh destroy ${VIRSH_CORDDEV_DOMAIN} || true
virsh undefine ${VIRSH_CORDDEV_DOMAIN} || true
xos-teardown: xos-update-images
$(ANSIBLE_PB) $(PI)/teardown-xos-playbook.yml $(LOGCMD)
rm -f $(M)/onboard-profile
rm -f $(M)/local-onboard-profile
xos-update-images: clean-images
rm -f $(M)/start-xos $(M)/local-start-xos
# local scenario helpers
clean-local: local-xos-teardown clean-profile clean-genconfig clean-images
rm -f $(LOCAL_MILESTONES)
local-ubuntu-dev-env:
$(ANSIBLE_PB) $(PI)/bootstrap-dev-env.yml $(LOGCMD)
local-xos-teardown: xos-update-images
$(eval COMPOSE_FILE := $(shell cd $(CONFIG_CORD_PROFILE_DIR); ls dynamic_load/* 2>/dev/null | tr '\n' ':')docker-compose.yml)
cd $(CONFIG_CORD_PROFILE_DIR); COMPOSE_FILE=$(COMPOSE_FILE) docker-compose -p $(PROFILE) rm -s -f || true
rm -f $(M)/local-onboard-profile
# ===== usage: make xos-service-config NAME=exampleservice PATH=exampleservice KEYPAIR=exampleservice_rsa =======
xos-service-config:
# NOTE check that variables are set before calling ansible?
$(ANSIBLE_PB) --extra-vars 'xos_dynamic_services={"name": $(NAME), "path"=$(PATH), "keypair"= $(KEYPAIR)}' $(PI)/xos-service-config.yml $(LOGCMD)
xos-services-up:
$(ANSIBLE_PB) $(PI)/xos-services-up.yml $(LOGCMD)
# wait for dynamic loading
DYNAMICLOAD_WAIT ?= 60
DYNAMICLOAD_URL ?= http://localhost:9101
DYNAMICLOAD_MODELS ?=
xos-wait-dynamicload:
python $(BUILD)/scripts/xos-wait-dynamicload.py $(DYNAMICLOAD_WAIT) $(DYNAMICLOAD_URL) $(DYNAMICLOAD_MODELS)
# docs
.PHONY: docs
docs:
cd docs; make
# == PREREQS == #
VAGRANT_UP_PREREQS ?=
COPY_CORD_PREREQS ?=
CORD_CONFIG_PREREQS ?=
CONFIG_SSH_KEY_PREREQS ?=
PREP_BUILDNODE_PREREQS ?=
PREP_HEADNODE_PREREQS ?=
PREP_KUBESPRAY_PREREQS ?=
DOCKER_IMAGES_PREREQS ?=
PUBLISH_DOCKER_IMAGES_PREREQS ?=
START_XOS_PREREQS ?=
BUILD_ONOS_APPS_PREREQS ?=
DEPLOY_ONOS_PREREQS ?=
DEPLOY_MAVENREPO_PREREQS ?=
DEPLOY_OPENSTACK_PREREQS ?=
ONBOARD_OPENSTACK_PREREQS ?=
SETUP_AUTOMATION_PREREQS ?=
TESTING_PREREQS ?=
# == MILESTONES == #
# empty target files are touched in the milestones dir to indicate completion
# Prep targets
$(M)/prereqs-check:
$(ANSIBLE_PB) $(PI)/prereqs-check-playbook.yml $(LOGCMD)
touch $@
$(M)/build-local-bootstrap:
$(ANSIBLE_PB) $(BUILD)/ansible/build-local-bootstrap.yml $(LOGCMD)
touch $@
$(M)/ciab-ovs:
$(ANSIBLE_PB) $(BUILD)/ansible/ciab-ovs.yml $(LOGCMD)
touch $@
$(M)/vagrant-up: | $(VAGRANT_UP_PREREQS)
$(VAGRANT) up $(VAGRANT_VMS) --provider $(VAGRANT_PROVIDER) $(LOGCMD)
touch $@
$(M)/vagrant-ssh-install: | $(M)/vagrant-up
$(VAGRANT) ssh-config $(VAGRANT_VMS) > /tmp/vagrant_ssh_config
$(ANSIBLE_PB) $(BUILD)/ansible/vagrant-ssh-install.yml $(LOGCMD)
touch $@
$(M)/config-ssh-key: | $(CONFIG_SSH_KEY_PREREQS)
$(ANSIBLE_PB) $(BUILD)/ansible/config-ssh-key.yml $(LOGCMD)
touch $@
$(M)/copy-cord: | $(COPY_CORD_PREREQS)
$(ANSIBLE_PB) $(PI)/copy-cord-playbook.yml $(LOGCMD)
touch $@
$(M)/cord-config: | $(CORD_CONFIG_PREREQS)
$(ANSIBLE_PB) $(PI)/cord-config-playbook.yml $(LOGCMD)
rm -rf $(CONFIG_CORD_PROFILE_DIR)/genconfig
cp -r $(GENCONFIG_D) $(CONFIG_CORD_PROFILE_DIR)/genconfig
touch $@
$(M)/copy-config: | $(M)/cord-config
$(ANSIBLE_PB) $(PI)/copy-profile-playbook.yml $(LOGCMD)
touch $@
$(M)/prep-buildnode: | $(M)/cord-config $(PREP_BUILDNODE_PREREQS)
$(ANSIBLE_PB) $(PI)/prep-buildnode-playbook.yml $(LOGCMD)
@echo Waiting 20 seconds to timeout SSH ControlPersist, and so future ansible commands gain docker group membership
sleep 20
touch $@
$(M)/prep-headnode: | $(M)/cord-config $(PREP_HEADNODE_PREREQS)
$(ANSIBLE_PB) $(PI)/prep-headnode-playbook.yml $(LOGCMD)
touch $@
$(M)/deploy-elasticstack: | $(M)/prep-headnode
$(ANSIBLE_PB) $(PI)/deploy-elasticstack-playbook.yml $(LOGCMD)
touch $@
$(M)/prep-computenode: | $(M)/prep-headnode
$(ANSIBLE_PB) $(PI)/prep-computenode-playbook.yml $(LOGCMD)
touch $@
# kubernetes targets
$(M)/prep-kubespray: | $(M)/prep-headnode $(M)/prep-computenode $(PREP_KUBESPRAY_PREREQS)
$(ANSIBLE_PB) $(BUILD)/ansible/prep-kubespray.yml $(LOGCMD)
touch $@
$(M)/deploy-kubespray: | $(M)/prep-kubespray
cd $(KUBESPRAY); $(ANSIBLE_PB_KS) cluster.yml $(LOGCMD)
touch $@
$(M)/finish-kubespray: | $(M)/deploy-kubespray
cd $(BUILD); $(ANSIBLE_PB) $(BUILD)/ansible/finish-kubespray.yml $(LOGCMD)
touch $@
$(M)/install-kubernetes-tools: | $(M)/finish-kubespray
$(ANSIBLE_PB) $(PI)/install-kubernetes-tools-playbook.yml $(LOGCMD)
touch $@
$(M)/start-xos-helm: | $(M)/install-kubernetes-tools $(M)/publish-docker-images
$(ANSIBLE_PB) $(PI)/start-xos-helm-playbook.yml $(LOGCMD)
touch $@
# MaaS targets
$(M)/build-maas-images: | $(M)/prep-buildnode $(BUILD_MAAS_IMAGES_PREREQS)
$(SSH_BUILD) "cd $(BUILD_CORD_DIR)/build/maas; rm -f consul.image; make MAKE_CONFIG=../$(MAKEFILE_CONFIG) build" $(LOGCMD)
touch $@
$(M)/maas-prime: | $(M)/prep-headnode
$(ANSIBLE_PB) $(MAAS)/prime-node.yml $(LOGCMD)
touch $@
$(M)/publish-maas-images: | $(M)/maas-prime $(M)/build-maas-images
$(SSH_BUILD) "cd $(BUILD_CORD_DIR)/build/maas; rm -f consul.publish; make MAKE_CONFIG=../$(MAKEFILE_CONFIG) publish" $(LOGCMD)
touch $@
$(M)/deploy-maas: | $(M)/publish-maas-images $(M)/cord-config $(M)/copy-config
$(ANSIBLE_PB) $(MAAS)/head-node.yml $(LOGCMD)
touch $@
# ONOS targets
$(M)/deploy-mavenrepo: | $(M)/docker-images $(DEPLOY_MAVENREPO_PREREQS)
$(ANSIBLE_PB) $(PI)/deploy-mavenrepo-playbook.yml $(LOGCMD)
touch $@
$(M)/deploy-onos: | $(M)/docker-images $(M)/deploy-mavenrepo $(DEPLOY_ONOS_PREREQS)
$(ANSIBLE_PB) $(PI)/deploy-onos-playbook.yml $(LOGCMD)
touch $@
$(M)/onos-debug: | $(M)/onboard-profile $(M)/deploy-onos
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) $(PI)/onos-debug-playbook.yml" $(LOGCMD)
touch $@
# XOS targets
$(M)/docker-images: | $(M)/prep-buildnode $(DOCKER_IMAGES_PREREQS)
$(SSH_BUILD) "cd $(BUILD_CORD_DIR)/build; $(IMAGEBUILDER) -f $(MASTER_CONFIG) -l $(BUILD)/image_logs -g $(BUILD)/ib_graph.dot -a $(BUILD)/ib_actions.yml " $(LOGCMD)
touch $@
# Requires ib_actions.yml file which is on the build host
$(M)/publish-docker-images: | $(M)/docker-images $(PUBLISH_DOCKER_IMAGES_PREREQS)
$(SSH_BUILD) "cd $(BUILD_CORD_DIR)/build; $(ANSIBLE_PB_LOCAL) $(PI)/publish-images-playbook.yml" $(LOGCMD)
touch $@
$(M)/start-xos: | $(M)/prep-headnode $(M)/cord-config $(M)/docker-images $(START_XOS_PREREQS)
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) $(PI)/start-xos-playbook.yml" $(LOGCMD)
touch $@
$(M)/onboard-profile: | $(M)/start-xos
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) $(PI)/onboard-profile-playbook.yml" $(LOGCMD)
touch $@
# OpenStack targets
$(M)/glance-images: | $(M)/prep-headnode
$(ANSIBLE_PB) $(PI)/glance-images-playbook.yml $(LOGCMD)
touch $@
$(M)/deploy-openstack: | $(M)/prep-headnode $(DEPLOY_OPENSTACK_PREREQS)
$(ANSIBLE_PB) $(PI)/deploy-openstack-playbook.yml $(LOGCMD)
touch $@
$(M)/deploy-computenode: | $(M)/prep-computenode $(M)/deploy-openstack
$(ANSIBLE_PB) $(PI)/deploy-computenode-playbook.yml $(LOGCMD)
touch $@
$(M)/onboard-openstack: | $(M)/deploy-computenode $(M)/glance-images $(M)/deploy-onos $(M)/onboard-profile $(ONBOARD_OPENSTACK_PREREQS)
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) $(PI)/onboard-openstack-playbook.yml" $(LOGCMD)
touch $@
# Post-onboarding targets
$(M)/setup-automation: | $(M)/onboard-profile $(M)/deploy-onos $(SETUP_AUTOMATION_PREREQS)
$(ANSIBLE_PB) $(PI)/cord-automation-playbook.yml $(LOGCMD)
touch $@
# Additional CiaB targets
$(M)/setup-ciab-pcu: | $(M)/setup-automation
$(ANSIBLE_PB) $(MAAS)/setup-ciab-pcu.yml
touch $@
$(M)/compute%-up: | $(M)/setup-ciab-pcu
$(VAGRANT) up compute$* --provider $(VAGRANT_PROVIDER) $(LOGCMD)
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) ansible/maas-provision.yml --extra-vars='maas_user=maas vagrant_name=cord_compute$*'" $(LOGCMD)
touch $@
compute1-up: | $(M)/compute1-up
compute2-up: | $(M)/compute2-up
compute3-up: | $(M)/compute3-up
# Fabric targets
fabric-refresh: | $(M)/setup-automation
$(ANSIBLE_PB) $(PI)/cord-refresh-fabric.yml $(LOGCMD)
fabric-pingtest:
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_MAAS) --private-key ~/.ssh/cord_rsa $(PI)/cord-fabric-pingtest.yml" $(LOGCMD)
# Testing targets
venv-xosapitest:
bash ../test/cord-tester/src/test/setup/venv-apitests.sh || true
xos-api-test: venv-xosapitest
bash -c "source venv-xosapitest/bin/activate && $(ANSIBLE_PB) $(PI)/xos-api-test-playbook.yml" $(LOGCMD)
clean-xos-api-tests:
rm -rf ../test/cord-tester/src/test/cord-api/Tests/Logs/*
rm -rf venv-xosapitest || true
# R-CORD specific targets
pod-test: | $(TESTING_PREREQS)
$(SSH_HEAD) "cd /opt/cord/build; $(ANSIBLE_PB_LOCAL) $(PI)/pod-test-playbook.yml" $(LOGCMD)
rcord-%:
$(ANSIBLE_PB) ../orchestration/profiles/rcord/test/rcord-$*-playbook.yml $(LOGCMD)
# M-CORD specific targets
mcord-%:
$(ANSIBLE_PB) ../orchestration/profiles/mcord/test/mcord-$*-playbook.yml $(LOGCMD)
# E-CORD specific targets
ecord-%:
$(ANSIBLE_PB) ../orchestration/profiles/ecord/test/ecord-$*-playbook.yml $(LOGCMD)
# Local Targets, bring up XOS containers without a VM
$(M)/local-cord-config:
$(ANSIBLE_PB) $(PI)/cord-config-playbook.yml $(LOGCMD)
touch $@
$(M)/local-docker-images: | $(M)/local-cord-config
$(IMAGEBUILDER) -f $(MASTER_CONFIG) -l $(BUILD)/image_logs -g $(BUILD)/ib_graph.dot -a $(BUILD)/ib_actions.yml $(LOGCMD)
touch $@
$(M)/local-start-xos: | $(M)/local-docker-images
$(ANSIBLE_PB) $(PI)/start-xos-playbook.yml $(LOGCMD)
touch $@
$(M)/local-onboard-profile: | $(M)/local-start-xos
$(ANSIBLE_PB) $(PI)/onboard-profile-playbook.yml $(LOGCMD)
touch $@