summaryrefslogtreecommitdiffstats
path: root/xci/installer/osa
diff options
context:
space:
mode:
Diffstat (limited to 'xci/installer/osa')
-rw-r--r--xci/installer/osa/files/ha/inventory4
-rw-r--r--xci/installer/osa/files/mini/inventory4
-rw-r--r--xci/installer/osa/files/noha/inventory4
-rw-r--r--xci/installer/osa/playbooks/configure-opnfvhost.yml15
-rw-r--r--xci/installer/osa/playbooks/configure-targethosts.yml42
5 files changed, 33 insertions, 36 deletions
diff --git a/xci/installer/osa/files/ha/inventory b/xci/installer/osa/files/ha/inventory
index 1ef4502a..f5d882ef 100644
--- a/xci/installer/osa/files/ha/inventory
+++ b/xci/installer/osa/files/ha/inventory
@@ -9,3 +9,7 @@ controller02 ansible_ssh_host=192.168.122.5
[compute]
compute00 ansible_ssh_host=192.168.122.6
compute01 ansible_ssh_host=192.168.122.7
+
+[openstack:children]
+controller
+compute
diff --git a/xci/installer/osa/files/mini/inventory b/xci/installer/osa/files/mini/inventory
index 63a1bfab..4224131f 100644
--- a/xci/installer/osa/files/mini/inventory
+++ b/xci/installer/osa/files/mini/inventory
@@ -6,3 +6,7 @@ controller00 ansible_ssh_host=192.168.122.3
[compute]
compute00 ansible_ssh_host=192.168.122.4
+
+[openstack:children]
+controller
+compute
diff --git a/xci/installer/osa/files/noha/inventory b/xci/installer/osa/files/noha/inventory
index 90b31531..0e3b8d84 100644
--- a/xci/installer/osa/files/noha/inventory
+++ b/xci/installer/osa/files/noha/inventory
@@ -7,3 +7,7 @@ controller00 ansible_ssh_host=192.168.122.3
[compute]
compute00 ansible_ssh_host=192.168.122.4
compute01 ansible_ssh_host=192.168.122.5
+
+[openstack:children]
+controller
+compute
diff --git a/xci/installer/osa/playbooks/configure-opnfvhost.yml b/xci/installer/osa/playbooks/configure-opnfvhost.yml
index 8b596b3c..4c30f4d1 100644
--- a/xci/installer/osa/playbooks/configure-opnfvhost.yml
+++ b/xci/installer/osa/playbooks/configure-opnfvhost.yml
@@ -75,12 +75,6 @@
- name: copy user_variables_ceph.yml
shell: "/bin/cp -rf {{ remote_xci_flavor_files }}/user_variables_ceph.yml {{OPENSTACK_OSA_ETC_PATH}}/user_variables_ceph.yml"
when: XCI_CEPH_ENABLED == "true"
- # TODO: We need to get rid of this as soon as the issue is fixed upstream
- - name: change the haproxy state from disable to enable
- replace:
- dest: "{{OPENSTACK_OSA_PATH}}/playbooks/os-keystone-install.yml"
- regexp: '(\s+)haproxy_state: disabled'
- replace: '\1haproxy_state: enabled'
- name: copy OPNFV OpenStack playbook
shell: "/bin/cp -rf {{ remote_xci_path }}/xci/installer/osa/files/setup-openstack.yml {{OPENSTACK_OSA_PATH}}/playbooks"
- name: copy pinned versions of OSA Roles and global requirements
@@ -136,6 +130,10 @@
content: "{{ xci_ssl_key }}"
dest: "/etc/ssl/private/xci.key"
become: true
+ - name: fetch xci environment
+ copy:
+ src: "{{ XCI_PATH }}/.cache/xci.env"
+ dest: /root/xci.env
- hosts: localhost
remote_user: root
@@ -173,3 +171,8 @@
src: "{{ ansible_env.HOME }}/openrc"
dest: "{{ XCI_PATH }}/.cache/openrc"
flat: true
+
+ - name: add public key to host
+ copy:
+ src: "{{ XCI_PATH }}/xci/files/authorized_keys"
+ dest: /root/.ssh/authorized_keys
diff --git a/xci/installer/osa/playbooks/configure-targethosts.yml b/xci/installer/osa/playbooks/configure-targethosts.yml
index 4341a884..31c3e02e 100644
--- a/xci/installer/osa/playbooks/configure-targethosts.yml
+++ b/xci/installer/osa/playbooks/configure-targethosts.yml
@@ -1,13 +1,5 @@
---
-- hosts: all
- remote_user: root
- tasks:
- - name: add public key to host
- copy:
- src: "{{ XCI_PATH }}/xci/files/authorized_keys"
- dest: /root/.ssh/authorized_keys
-
-- hosts: controller
+- hosts: openstack
remote_user: root
vars_files:
- "{{ XCI_PATH }}/xci/var/opnfv.yml"
@@ -21,25 +13,15 @@
- "{{ XCI_FLAVOR_ANSIBLE_FILE_PATH }}/flavor-vars.yml"
roles:
- role: bootstrap-host
-
-- hosts: compute
- remote_user: root
- vars_files:
- - "{{ XCI_PATH }}/xci/var/opnfv.yml"
-
- pre_tasks:
- - name: Load distribution variables
- include_vars:
- file: "{{ item }}"
- with_items:
- - "{{ XCI_PATH }}/xci/var/{{ ansible_os_family }}.yml"
- - "{{ XCI_FLAVOR_ANSIBLE_FILE_PATH }}/flavor-vars.yml"
- roles:
- - role: bootstrap-host
- - role: configure-ceph
- when: XCI_CEPH_ENABLED == "true"
-
-- hosts: compute00
- remote_user: root
- roles:
- role: configure-nfs
+ when:
+ - "'compute' in group_names"
+ - role: configure-ceph
+ when:
+ - XCI_CEPH_ENABLED == "true"
+ - "'compute' in group_names"
+ tasks:
+ - name: add public key to host
+ copy:
+ src: "{{ XCI_PATH }}/xci/files/authorized_keys"
+ dest: /root/.ssh/authorized_keys