diff options
Diffstat (limited to 'deploy/adapters/ansible/roles/glance/tasks')
3 files changed, 8 insertions, 11 deletions
diff --git a/deploy/adapters/ansible/roles/glance/tasks/glance_config.yml b/deploy/adapters/ansible/roles/glance/tasks/glance_config.yml index 008595dc..0960acfc 100644 --- a/deploy/adapters/ansible/roles/glance/tasks/glance_config.yml +++ b/deploy/adapters/ansible/roles/glance/tasks/glance_config.yml @@ -1,6 +1,7 @@ --- - name: init glance db version shell: glance-manage db_version_control 0 + when: ansible_os_family == "Debian" - name: sync glance db shell: sleep 15; su -s /bin/sh -c "glance-manage db_sync" glance @@ -9,8 +10,7 @@ retries: 5 delay: 3 notify: - - restart glance-registry - - restart glance-api + - restart glance services - meta: flush_handlers diff --git a/deploy/adapters/ansible/roles/glance/tasks/glance_install.yml b/deploy/adapters/ansible/roles/glance/tasks/glance_install.yml index d9d15db3..294b35e8 100644 --- a/deploy/adapters/ansible/roles/glance/tasks/glance_install.yml +++ b/deploy/adapters/ansible/roles/glance/tasks/glance_install.yml @@ -1,13 +1,11 @@ --- -- include_vars: "{{ ansible_os_family }}.yml" - - name: install glance packages - action: "{{ ansible_pkg_mgr }} name={{ item }} state=latest force=yes" - with_items: glance_packages + action: "{{ ansible_pkg_mgr }} name={{ item }} state=latest" + with_items: packages | union(packages_noarch) - name: generate glance service list shell: echo {{ item }} >> /opt/service - with_items: glance_services + with_items: services | union(services_noarch) - name: update glance conf template: src={{ item }} dest=/etc/glance/{{ item }} @@ -16,8 +14,7 @@ - glance-api.conf - glance-registry.conf notify: - - restart glance-registry - - restart glance-api + - restart glance services - name: remove default sqlite db shell: rm /var/lib/glance/glance.sqlite || touch glance.sqllite.db.removed diff --git a/deploy/adapters/ansible/roles/glance/tasks/nfs.yml b/deploy/adapters/ansible/roles/glance/tasks/nfs.yml index 70ed91d5..dc1be977 100644 --- a/deploy/adapters/ansible/roles/glance/tasks/nfs.yml +++ b/deploy/adapters/ansible/roles/glance/tasks/nfs.yml @@ -1,7 +1,7 @@ --- - name: install packages - action: "{{ ansible_pkg_mgr }} name=nfs-common state=present" - with_items: nfs-packages + action: "{{ ansible_pkg_mgr }} name={{ item }} state=present" + with_items: nfs_packages - name: install nfs local_action: yum name=nfs-utils state=present |