diff options
author | 2017-04-18 14:51:27 +0000 | |
---|---|---|
committer | 2017-04-18 14:51:27 +0000 | |
commit | 2f9aacfdf788dc5ee5b38c2eb155c315ac758d17 (patch) | |
tree | d1ad01eea7b9c6c0f8f2534a8106bf5f60a74443 /prototypes/xci/playbooks | |
parent | 283f6dcfbc101beb9ad85596f03c04529a7c0e61 (diff) | |
parent | f11607f063a53948d756d9b2666e5b9771869ebc (diff) |
Merge "xci: Merge configure-targethosts.yml playbooks into one"
Diffstat (limited to 'prototypes/xci/playbooks')
-rw-r--r-- | prototypes/xci/playbooks/configure-localhost.yml | 6 | ||||
-rw-r--r-- | prototypes/xci/playbooks/configure-targethosts.yml | 36 |
2 files changed, 36 insertions, 6 deletions
diff --git a/prototypes/xci/playbooks/configure-localhost.yml b/prototypes/xci/playbooks/configure-localhost.yml index 2a559645e..34b974cd1 100644 --- a/prototypes/xci/playbooks/configure-localhost.yml +++ b/prototypes/xci/playbooks/configure-localhost.yml @@ -21,12 +21,6 @@ path: "{{LOG_PATH}}" state: directory recurse: no - # when the deployment is not aio, we use playbook, configure-targethosts.yml, to configure all the hosts - - name: copy multihost playbook - copy: - src: "{{XCI_FLAVOR_ANSIBLE_FILE_PATH}}/configure-targethosts.yml" - dest: "{{OPNFV_RELENG_PATH}}/prototypes/xci/playbooks" - when: XCI_FLAVOR != "aio" # when the deployment is aio, we overwrite and use playbook, configure-opnfvhost.yml, since everything gets installed on opnfv host - name: copy aio playbook copy: diff --git a/prototypes/xci/playbooks/configure-targethosts.yml b/prototypes/xci/playbooks/configure-targethosts.yml new file mode 100644 index 000000000..50da1f223 --- /dev/null +++ b/prototypes/xci/playbooks/configure-targethosts.yml @@ -0,0 +1,36 @@ +--- +- hosts: all + remote_user: root + tasks: + - name: add public key to host + copy: + src: ../file/authorized_keys + dest: /root/.ssh/authorized_keys + +- hosts: controller + remote_user: root + vars_files: + - ../var/{{ ansible_os_family }}.yml + - ../var/flavor-vars.yml + roles: + # TODO: this only works for ubuntu/xenial and need to be adjusted for other distros + - { role: configure-network, src: "../template/controller.interface.j2", dest: "/etc/network/interfaces" } + # we need to force sync time with ntp or the nodes will be out of sync timewise + - role: synchronize-time + +- hosts: compute + remote_user: root + vars_files: + - ../var/{{ ansible_os_family }}.yml + - ../var/flavor-vars.yml + roles: + # TODO: this only works for ubuntu/xenial and need to be adjusted for other distros + - { role: configure-network, src: "../template/compute.interface.j2", dest: "/etc/network/interfaces" } + # we need to force sync time with ntp or the nodes will be out of sync timewise + - role: synchronize-time + +- hosts: compute00 + remote_user: root + # TODO: this role is for configuring NFS on xenial and adjustment needed for other distros + roles: + - role: configure-nfs |