Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 1 | # cord-pod/Makefile |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 2 | |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 3 | CONFIG_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) |
| 4 | COMMON_DIR := $(abspath ../common ) |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 5 | |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 6 | .DEFAULT_GOAL := xos |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 7 | |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 8 | DOCKER_PROJECT ?= cordpod |
| 9 | BOOTSTRAP_PROJECT ?= cordpodbs |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 10 | |
Scott Baker | 0d369d1 | 2016-11-08 16:37:30 -0800 | [diff] [blame] | 11 | XOS_UI_PORT := 8888 |
| 12 | |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 13 | # Include common functions |
| 14 | include $(COMMON_DIR)/Makefile |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 15 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 16 | xos: prereqs config_dirs xos_download cord_services cord_libraries bootstrap onboarding |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 17 | |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 18 | onboarding: synchronizers.yaml id_rsa id_rsa.pub |
Scott Baker | c5e2f3c | 2016-07-11 11:48:06 -0700 | [diff] [blame] | 19 | @echo "[ONBOARDING]" |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 20 | # on-board any services here |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 21 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) xos |
| 22 | $(RUN_TOSCA_BOOTSTRAP) $(COMMON_DIR)/tosca/disable-onboarding.yaml |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 23 | sudo cp id_rsa key_import/vsg_rsa |
| 24 | sudo cp id_rsa.pub key_import/vsg_rsa.pub |
| 25 | sudo cp id_rsa key_import/volt_rsa |
| 26 | sudo cp id_rsa.pub key_import/volt_rsa.pub |
| 27 | sudo cp id_rsa key_import/onos_rsa |
| 28 | sudo cp id_rsa key_import/onos_rsa.pub |
Scott Baker | da3b159 | 2016-10-24 10:45:36 -0700 | [diff] [blame] | 29 | $(RUN_TOSCA_BOOTSTRAP) $(LIBRARY_DIR)/ng-xos-lib/ng-xos-lib-onboard.yaml |
Scott Baker | 989959c | 2016-08-11 19:22:52 -0700 | [diff] [blame] | 30 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/openstack/xos/openstack-onboard.yaml |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 31 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/vrouter/xos/vrouter-onboard.yaml |
| 32 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/olt/xos/volt-onboard.yaml |
| 33 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/vsg/xos/vsg-onboard.yaml |
| 34 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/vtn/xos/vtn-onboard.yaml |
| 35 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/onos-service/xos/onos-onboard.yaml |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 36 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/fabric/xos/fabric-onboard.yaml |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 37 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/vtr/xos/vtr-onboard.yaml |
| 38 | $(RUN_TOSCA_BOOTSTRAP) synchronizers.yaml |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 39 | $(RUN_TOSCA_BOOTSTRAP) $(COMMON_DIR)/tosca/enable-onboarding.yaml |
Scott Baker | da3b159 | 2016-10-24 10:45:36 -0700 | [diff] [blame] | 40 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/ng-xos-lib |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 41 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/vrouter |
| 42 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/volt |
| 43 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/vsg |
| 44 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/vtn |
| 45 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/onos |
| 46 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/fabric |
| 47 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/vtr |
| 48 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) xos |
| 49 | bash $(COMMON_DIR)/wait_for_xos_port.sh $(XOS_UI_PORT) |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 50 | sleep 120 |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 51 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 52 | nodes: nodes.yaml |
| 53 | @echo "[NODES]" |
| 54 | $(RUN_TOSCA) openstack.yaml |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 55 | $(RUN_TOSCA) nodes.yaml |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 56 | sleep 10 |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 57 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 58 | vtn: nodes vtn.yaml |
| 59 | @echo "[VTN]" |
| 60 | $(RUN_TOSCA) vtn.yaml |
Zack Williams | d7d58f1 | 2016-10-24 23:11:06 -0700 | [diff] [blame] | 61 | |
Andy Bavier | 712e134 | 2016-07-28 17:01:53 -0400 | [diff] [blame] | 62 | delete_fabric_config: |
Andy Bavier | abdbf30 | 2016-07-28 20:25:53 -0400 | [diff] [blame] | 63 | http -a karaf:karaf DELETE http://onos-fabric:8181/onos/v1/network/configuration/ |
Andy Bavier | 712e134 | 2016-07-28 17:01:53 -0400 | [diff] [blame] | 64 | |
| 65 | reactivate_fabric_apps: |
Andy Bavier | abdbf30 | 2016-07-28 20:25:53 -0400 | [diff] [blame] | 66 | http -a karaf:karaf POST http://onos-fabric:8181/onos/v1/applications/org.onosproject.vrouter/active |
| 67 | http -a karaf:karaf POST http://onos-fabric:8181/onos/v1/applications/org.onosproject.segmentrouting/active |
Andy Bavier | 712e134 | 2016-07-28 17:01:53 -0400 | [diff] [blame] | 68 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 69 | fabric: |
| 70 | @echo "[FABRIC]" |
Zack Williams | d7d58f1 | 2016-10-24 23:11:06 -0700 | [diff] [blame] | 71 | cp $(SERVICE_DIR)/fabric/config/network-cfg-quickstart.json . |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 72 | $(RUN_TOSCA) fabric.yaml |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 73 | sleep 20 |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 74 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 75 | cord: |
| 76 | @echo "[CORD]" |
| 77 | $(RUN_TOSCA) management-net.yaml |
Andy Bavier | acfadd4 | 2016-06-30 16:46:32 -0400 | [diff] [blame] | 78 | $(RUN_TOSCA) cord-services.yaml |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 79 | $(RUN_TOSCA) public-net.yaml |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 80 | $(RUN_TOSCA) $(COMMON_DIR)/tosca/cord-volt-devices.yaml |
| 81 | |
Matteo Scandolo | 44bf891 | 2016-11-21 13:56:04 -0800 | [diff] [blame] | 82 | vrouter: |
| 83 | $(RUN_TOSCA) ./vrouter.yaml |
| 84 | |
Andy Bavier | acfadd4 | 2016-06-30 16:46:32 -0400 | [diff] [blame] | 85 | cord-subscriber: |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 86 | @echo "[CORD-SUBSCRIBER]" |
Andy Bavier | acfadd4 | 2016-06-30 16:46:32 -0400 | [diff] [blame] | 87 | $(RUN_TOSCA) cord-test-subscriber.yaml |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 88 | sleep 60 |
Andy Bavier | acfadd4 | 2016-06-30 16:46:32 -0400 | [diff] [blame] | 89 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 90 | exampleservice: $(SERVICE_DIR)/exampleservice |
| 91 | @echo "[EXAMPLESERVICE]" |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 92 | sudo cp id_rsa key_import/exampleservice_rsa |
| 93 | sudo cp id_rsa.pub key_import/exampleservice_rsa.pub |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 94 | $(RUN_TOSCA_BOOTSTRAP) $(COMMON_DIR)/tosca/disable-onboarding.yaml |
Scott Baker | df81f59 | 2016-07-14 12:01:21 -0700 | [diff] [blame] | 95 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/exampleservice/xos/exampleservice-onboard.yaml |
Scott Baker | 78ea35a | 2016-07-25 08:55:16 -0700 | [diff] [blame] | 96 | $(RUN_TOSCA_BOOTSTRAP) exampleservice-synchronizer.yaml |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 97 | $(RUN_TOSCA_BOOTSTRAP) $(COMMON_DIR)/tosca/enable-onboarding.yaml |
| 98 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/exampleservice |
| 99 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) xos |
| 100 | bash $(COMMON_DIR)/wait_for_xos_port.sh $(XOS_UI_PORT) |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 101 | $(RUN_TOSCA) exampleservice.yaml |
| 102 | sleep 60 |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 103 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 104 | cord-monitoringservice: $(SERVICE_DIR)/monitoring |
| 105 | @echo "[CORD-MONITORINGSERVICE]" |
Scott Baker | d1545d3 | 2016-06-29 11:27:33 -0700 | [diff] [blame] | 106 | sudo cp id_rsa key_import/monitoringservice_rsa |
| 107 | sudo cp id_rsa.pub key_import/monitoringservice_rsa.pub |
| 108 | $(RUN_TOSCA_BOOTSTRAP) $(SERVICE_DIR)/monitoring/xos/monitoring-onboard.yaml |
Srikanth Vavilapalli | 4cf2fed | 2016-07-01 21:27:20 +0000 | [diff] [blame] | 109 | $(RUN_TOSCA_BOOTSTRAP) monitoring_synchronizer.yaml |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 110 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) services/monitoring |
| 111 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) xos |
| 112 | bash $(COMMON_DIR)/wait_for_xos_port.sh $(XOS_UI_PORT) |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 113 | $(RUN_TOSCA) monitoringservice.yaml |
| 114 | $(RUN_TOSCA) monitoringtenant.yaml |
Srikanth Vavilapalli | 6594b75 | 2016-12-13 00:31:13 +0000 | [diff] [blame] | 115 | @echo "waiting for monitoring service to be fully ready...." |
| 116 | ansible-playbook -i local $(SERVICE_DIR)/monitoring/xos/test/monitoring_test_initial.yaml |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 117 | |
Zack Williams | cf1f9c8 | 2016-11-08 22:19:02 -0700 | [diff] [blame] | 118 | rebuild-monitoringservice: |
| 119 | bash $(COMMON_DIR)/rebuild.sh $(XOS_BOOTSTRAP_PORT) monitoring |
| 120 | bash $(COMMON_DIR)/wait_for_onboarding_ready.sh $(XOS_BOOTSTRAP_PORT) xos |
Srikanth Vavilapalli | 0fc7de7 | 2016-11-03 17:49:11 +0000 | [diff] [blame] | 121 | |
Srikanth Vavilapalli | 7da3c5e | 2016-10-13 17:50:21 +0000 | [diff] [blame] | 122 | install-inframonitoring-agents: |
| 123 | bash $(SERVICE_DIR)/monitoring/xos/synchronizer/ceilometer/monitoring_agent/install_monitoring_ceilometer.sh |
| 124 | |
| 125 | enable-inframonitoring: inframonitoring_yaml |
| 126 | $(RUN_TOSCA) inframonitoring.yaml |
Srikanth Vavilapalli | 6594b75 | 2016-12-13 00:31:13 +0000 | [diff] [blame] | 127 | @echo "Validate if infra metrics are available...." |
| 128 | ansible-playbook -i local $(SERVICE_DIR)/monitoring/xos/test/monitoring_test_inframetrics.yaml |
Srikanth Vavilapalli | 7da3c5e | 2016-10-13 17:50:21 +0000 | [diff] [blame] | 129 | |
| 130 | enable-vsgmonitoring: |
| 131 | $(RUN_TOSCA) vsgmonitoring.yaml |
Srikanth Vavilapalli | 6594b75 | 2016-12-13 00:31:13 +0000 | [diff] [blame] | 132 | @echo "Validate if vSG metrics are available...." |
| 133 | ansible-playbook -i local $(SERVICE_DIR)/monitoring/xos/test/monitoring_test_vsgmetrics.yaml |
Srikanth Vavilapalli | 7da3c5e | 2016-10-13 17:50:21 +0000 | [diff] [blame] | 134 | |
| 135 | enable-exampleservicemonitoring: |
| 136 | $(RUN_TOSCA) exampleservicemonitoring.yaml |
| 137 | |
| 138 | inframonitoring_yaml: |
| 139 | export SETUPDIR=$(CONFIG_DIR); bash ./make-inframonitoring-yaml.sh |
| 140 | |
Scott Baker | 5042166 | 2016-06-27 22:09:48 -0700 | [diff] [blame] | 141 | virtualbng_json: |
Zack Williams | 3670f44 | 2016-10-04 17:37:12 -0700 | [diff] [blame] | 142 | export SETUPDIR=$(CONFIG_DIR); bash ./make-virtualbng-json.sh |