summaryrefslogtreecommitdiffstats
path: root/tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml
diff options
context:
space:
mode:
authorMichal Ptacek <m.ptacek@partner.samsung.com>2019-09-04 15:39:20 +0000
committerGerrit Code Review <gerrit@onap.org>2019-09-04 15:39:20 +0000
commit1da8b7af533aa48450d42219f0615d0bb510da4a (patch)
tree827fc4fa9da8d685d6d7960978ce99680e8f7d31 /tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml
parent8620b2be770895ffca1385f3a8a57b9422ecf126 (diff)
parent2e34522351d40edd0e37b4919630736748949f2a (diff)
Merge changes from topic "OOM-2042"
* changes: Add ansible configuration file Add cicdansible playbook Add onap installation role Add onap instance configuration role Add ansible role to deploy onap infrastructure on openstack Add floating ip fact retrieval module Add inventory for cicdansible playbook Add heat template to deploy onap infrastructure Add the .gitignore for cicdansible
Diffstat (limited to 'tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml')
-rw-r--r--tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml9
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml b/tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml
new file mode 100644
index 00000000..a50ecd22
--- /dev/null
+++ b/tools/cicdansible/roles/setup_openstack_infrastructure/tasks/deploy/register_instances.yml
@@ -0,0 +1,9 @@
+#Register instances as hosts in inventory.
+#Installer and infra are statically registered.
+#Register node instances dynamically.
+- name: "Register node instances"
+ add_host:
+ name: "node{{ item[0] }}"
+ groups: nodes
+ ansible_host: "{{ item[1] }}"
+ loop: "{{ query('indexed_items', (heat_stack.stack.outputs | selectattr('output_key', 'equalto', 'node_ips') | list).0.output_value) }}"