diff options
author | baigk <baiguoku@huawei.com> | 2015-08-06 02:37:33 -0400 |
---|---|---|
committer | baigk <baiguoku@huawei.com> | 2015-08-09 22:47:56 -0400 |
commit | 87612abc0e24cafd89a49e350165b08fe1608233 (patch) | |
tree | 07b156c0268fd189f92e8a0730118edc51b8073f /deploy/adapters/ansible/roles/nova-compute | |
parent | 5aedf594112c0749b6e9039d15b9fe70d210a942 (diff) |
support deployment openstack juno with ansible for compass in centos7.1
JIRA: COMPASS-6
Change-Id: I8ef865e8acfe29c3ff5c7e9030e4cebabed3457b
Signed-off-by: baigk <baiguoku@huawei.com>
Diffstat (limited to 'deploy/adapters/ansible/roles/nova-compute')
6 files changed, 22 insertions, 9 deletions
diff --git a/deploy/adapters/ansible/roles/nova-compute/handlers/main.yml b/deploy/adapters/ansible/roles/nova-compute/handlers/main.yml index c1350030..6910c810 100644 --- a/deploy/adapters/ansible/roles/nova-compute/handlers/main.yml +++ b/deploy/adapters/ansible/roles/nova-compute/handlers/main.yml @@ -1,3 +1,4 @@ --- -- name: restart nova-compute - service: name=nova-compute state=restarted enabled=yes +- name: restart nova-compute services + service: name={{ item }} state=restarted enabled=yes + with_items: services | union(services_noarch) diff --git a/deploy/adapters/ansible/roles/nova-compute/tasks/main.yml b/deploy/adapters/ansible/roles/nova-compute/tasks/main.yml index 6c426898..14c5450d 100644 --- a/deploy/adapters/ansible/roles/nova-compute/tasks/main.yml +++ b/deploy/adapters/ansible/roles/nova-compute/tasks/main.yml @@ -2,8 +2,8 @@ - include_vars: "{{ ansible_os_family }}.yml" - name: install nova-compute related packages - action: "{{ ansible_pkg_mgr }} name={{ item }} state=present force=yes" - with_items: packages + action: "{{ ansible_pkg_mgr }} name={{ item }} state=present" + with_items: packages | union(packages_noarch) - name: update nova-compute conf template: src={{ item }} dest=/etc/nova/{{ item }} @@ -11,11 +11,11 @@ - nova.conf - nova-compute.conf notify: - - restart nova-compute + - restart nova-compute services -- name: generate neutron controll service list +- name: generate neutron control service list shell: echo {{ item }} >> /opt/service - with_items: services + with_items: services | union(services_noarch) - meta: flush_handlers diff --git a/deploy/adapters/ansible/roles/nova-compute/templates/nova.conf b/deploy/adapters/ansible/roles/nova-compute/templates/nova.conf index 4988cb03..4706d1db 100644 --- a/deploy/adapters/ansible/roles/nova-compute/templates/nova.conf +++ b/deploy/adapters/ansible/roles/nova-compute/templates/nova.conf @@ -3,7 +3,7 @@ dhcpbridge_flagfile=/etc/nova/nova.conf dhcpbridge=/usr/bin/nova-dhcpbridge logdir=/var/log/nova state_path=/var/lib/nova -lock_path=/var/lock/nova +lock_path=/var/lib/nova/tmp force_dhcp_release=True iscsi_helper=tgtadm libvirt_use_virtio_for_bridges=True diff --git a/deploy/adapters/ansible/roles/nova-compute/vars/Debian.yml b/deploy/adapters/ansible/roles/nova-compute/vars/Debian.yml index ab2d7301..985b329e 100644 --- a/deploy/adapters/ansible/roles/nova-compute/vars/Debian.yml +++ b/deploy/adapters/ansible/roles/nova-compute/vars/Debian.yml @@ -1,7 +1,7 @@ --- + packages: - nova-compute-kvm services: - nova-compute - diff --git a/deploy/adapters/ansible/roles/nova-compute/vars/RedHat.yml b/deploy/adapters/ansible/roles/nova-compute/vars/RedHat.yml new file mode 100644 index 00000000..7f5d388d --- /dev/null +++ b/deploy/adapters/ansible/roles/nova-compute/vars/RedHat.yml @@ -0,0 +1,8 @@ +--- +packages: + - openstack-nova-compute + - sysfsutils + +services: + - libvirtd + - openstack-nova-compute diff --git a/deploy/adapters/ansible/roles/nova-compute/vars/main.yml b/deploy/adapters/ansible/roles/nova-compute/vars/main.yml new file mode 100644 index 00000000..d43b8359 --- /dev/null +++ b/deploy/adapters/ansible/roles/nova-compute/vars/main.yml @@ -0,0 +1,4 @@ +--- +packages_noarch: [] + +services_noarch: [] |