CORD-714
initial set of roles/playbooks
bug fixes
fix docker-compose logging, pull xos-base image
dynamically add docker instances to ansible inventory after onboarding
Bootstrap the onboarding synchronizer
more defaults, reload vars after adding docker inventory
move TOSCA templates to cord-profilea, random password on admin
fixes for docker compose, paths in xos.yaml in jinja
don't try to mangle XOS _config files (yet)
create xos-test image
make xos-test use locally build xosproject/xos
add docker-compose v2 format networking
fix docker-compose template
path fixes, move ssh keys
service names/paths aren't so simple
added api-tests, teardown roles
scan the onboarded docker-compose file for ansible inventory
add various tests used by test-standalone profile
fixes for API tests
save test output to /tmp/<testname>.out, bugfixes
autogenerate openstack keystone admin password, fix tests
remove nonfunctional UI tests
change location of cord_profile, use inventory to specify profile
fix YAML escaping of backslashes in regex
bugfixes after path change, add teardown playbook
backout setting of cord_dir with ansible_user_dir which differs depending on context
gradle build fixes, renaming
fix yml/yaml naming issue
null xos_images default
added rcord/mcord frontend variants, exampleservice onboarding
add missing role, help text in cord-bootstrap.sh
bugfix
create/run deployment.yaml by default
allow teardown to handle partially built pods, bugfix to deployment.yaml generation
add defaults, fix path for exampleservice
revert yaml naming to ease testing, rename mocks
debugging
exampleservice onboarding, mounting volume in XOS container
bugfix
add volume mounts when creating xos_ui, don't double add to ansible inventory
post-onboard TOSCA cnfig
typo fixes, order of loading TOSCA
config bits for cord-pod, some var renaming
update documentation, rename to rcord
doc fixes
support for building just before XOS install, docs
fix tests, refactor how compute nodes are configed, split vtn service config from adding a node
remove build process from deploy repo
inclusion/merge of PKI support
typo
bugfixes and change to use cord instead of opencord for install dir
fix pki support
fix ssh key paths
update xos ui/bs ports, fix onboarding on vagrant
have compute enlist script use same config file as other playbooks
fix ports, add MaaS version of compute node enable script
fix port and nodes.yaml loading
generate API SSL cert for all profiles
remove cord-app-build which is vestigial
remove config dir
default xos_ui_port in xos-ready role
use xostosca from service-profie/cord-pod-ansible to handle POST form-encode
fix nodes.yaml, variable name in xostosca, and include openstack properly
copy cert chain to build into XOS container
increase onboarding timeouts, don't restart docker
fix ONOS app versions and network settings
fix management_hosts network optional include
fix management/fabric settings
avoid modifying service#ONOS_CORD when adding nodes
split out compute node and vtn config, put delay between
fix template generation and fail on file not found
rename vars to profile_manifests, fix redis include
whitespace fix
increase timeout
reenable platform-check
parameterize node_key path, set defaults and fix platform-check
workaround for onboarding sync, minor fixes
pause in middle of VTN bug workaround
reload openstack config as well
disable platform-check role as a test
fixed head-diag role
reapply VTN config during compute node enable
Create exampleservice instance during test
Change-Id: I87e171bcfa429e65e1075a1ee4c97de1e90a7dd5
diff --git a/roles/exampleservice-onboard/defaults/main.yml b/roles/exampleservice-onboard/defaults/main.yml
new file mode 100644
index 0000000..463326e
--- /dev/null
+++ b/roles/exampleservice-onboard/defaults/main.yml
@@ -0,0 +1,8 @@
+---
+# exampleservice-onboard/defaults/main.yml
+
+cord_dir: "{{ ansible_user_dir + '/cord' }}"
+cord_profile_dir: "{{ ansible_user_dir + '/cord_profile' }}"
+
+xos_bootstrap_ui_port: 9001
+
diff --git a/roles/exampleservice-onboard/tasks/main.yml b/roles/exampleservice-onboard/tasks/main.yml
new file mode 100644
index 0000000..ba559d1
--- /dev/null
+++ b/roles/exampleservice-onboard/tasks/main.yml
@@ -0,0 +1,43 @@
+---
+# exampleservice-onboard/tasks/main.yml
+
+- name: Disable onboarding
+ command: "python /opt/xos/tosca/run.py {{ xos_admin_user }} /opt/cord_profile/disable-onboarding.yaml"
+ tags:
+ - skip_ansible_lint # TOSCA loading should be idempotent
+
+- name: Have XOS container mount exampleservice volume
+ command: "python /opt/xos/tosca/run.py {{ xos_admin_user }} /opt/cord_profile/xos-exampleservice.yaml"
+ tags:
+ - skip_ansible_lint # TOSCA loading should be idempotent
+
+- name: Onboard exampleservice
+ command: "python /opt/xos/tosca/run.py {{ xos_admin_user }} /opt/cord_profile/exampleservice-onboard.yaml"
+ tags:
+ - skip_ansible_lint # TOSCA loading should be idempotent
+
+- name: Enable onboarding
+ command: "python /opt/xos/tosca/run.py {{ xos_admin_user }} /opt/cord_profile/enable-onboarding.yaml"
+ tags:
+ - skip_ansible_lint # TOSCA loading should be idempotent
+
+- name: Wait for exampleservice to be onboarded
+ uri:
+ url: "http://localhost:{{ xos_bootstrap_ui_port }}/api/utility/onboarding/services/exampleservice/ready/"
+ method: GET
+ return_content: yes
+ register: xos_onboard_status
+ until: '"true" in xos_onboard_status.content'
+ retries: 60
+ delay: 2
+
+- name: Wait for XOS to be onboarded after exampleservice onboarding
+ uri:
+ url: "http://localhost:{{ xos_bootstrap_ui_port }}/api/utility/onboarding/xos/ready/"
+ method: GET
+ return_content: yes
+ register: xos_onboard_status
+ until: '"true" in xos_onboard_status.content'
+ retries: 60
+ delay: 2
+