From 5e35fc54a64732b91d3cbde68a47f1062432d253 Mon Sep 17 00:00:00 2001 From: Duong Ha-Quang Date: Wed, 17 Aug 2016 16:25:55 +0700 Subject: [PATCH] Port with_ loop variable syntax to Ansbile 2 (finish) Migrate to full variable syntax in with_ loop instead of bare variables for: - cinder - haproxy - ironic - magnum - mistral - mongodb - murano - swift - watcher TrivialFix Change-Id: I3ef2e79053cf609aaa710e43ffd0adbc5a97565b --- ansible/roles/cinder/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/haproxy/tasks/do_reconfigure.yml | 4 ++-- ansible/roles/ironic/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/magnum/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/mistral/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/mongodb/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/murano/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/swift/tasks/do_reconfigure.yml | 8 ++++---- ansible/roles/swift/tasks/start.yml | 2 +- ansible/roles/watcher/tasks/do_reconfigure.yml | 8 ++++---- 10 files changed, 35 insertions(+), 35 deletions(-) diff --git a/ansible/roles/cinder/tasks/do_reconfigure.yml b/ansible/roles/cinder/tasks/do_reconfigure.yml index 91abc1525a..af453c8875 100644 --- a/ansible/roles/cinder/tasks/do_reconfigure.yml +++ b/ansible/roles/cinder/tasks/do_reconfigure.yml @@ -55,8 +55,8 @@ { name: cinder_scheduler, group: cinder-scheduler }, { name: cinder_volume, group: cinder-volume }, { name: cinder_backup, group: cinder-backup }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -75,5 +75,5 @@ { name: cinder_scheduler, group: cinder-scheduler }, { name: cinder_volume, group: cinder-volume }, { name: cinder_backup, group: cinder-backup }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/haproxy/tasks/do_reconfigure.yml b/ansible/roles/haproxy/tasks/do_reconfigure.yml index 034f28f6cf..ea2b3dfc02 100644 --- a/ansible/roles/haproxy/tasks/do_reconfigure.yml +++ b/ansible/roles/haproxy/tasks/do_reconfigure.yml @@ -44,8 +44,8 @@ with_together: - [{ name: haproxy, group: haproxy }, { name: keepalived, group: haproxy }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed diff --git a/ansible/roles/ironic/tasks/do_reconfigure.yml b/ansible/roles/ironic/tasks/do_reconfigure.yml index ee0b3bd435..392c8219c9 100644 --- a/ansible/roles/ironic/tasks/do_reconfigure.yml +++ b/ansible/roles/ironic/tasks/do_reconfigure.yml @@ -52,8 +52,8 @@ { name: ironic_api, group: ironic-api }, { name: ironic_conductor, group: ironic-conductor }, { name: ironic_inspector, group: ironic-inspector }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -72,5 +72,5 @@ { name: ironic_api, group: ironic-api }, { name: ironic_conductor, group: ironic-conductor }, { name: ironic_inspector, group: ironic-inspector }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/magnum/tasks/do_reconfigure.yml b/ansible/roles/magnum/tasks/do_reconfigure.yml index 34f884169e..9598ffb89d 100644 --- a/ansible/roles/magnum/tasks/do_reconfigure.yml +++ b/ansible/roles/magnum/tasks/do_reconfigure.yml @@ -47,8 +47,8 @@ with_together: - [{ name: magnum_api, group: magnum-api }, { name: magnum_conductor, group: magnum-conductor }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -65,5 +65,5 @@ with_together: - [{ name: magnum_api, group: magnum-api }, { name: magnum_conductor, group: magnum-conductor }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/mistral/tasks/do_reconfigure.yml b/ansible/roles/mistral/tasks/do_reconfigure.yml index 2b7f3324ef..d0d9e7ae97 100644 --- a/ansible/roles/mistral/tasks/do_reconfigure.yml +++ b/ansible/roles/mistral/tasks/do_reconfigure.yml @@ -48,8 +48,8 @@ - [{ name: mistral_api, group: mistral-api }, { name: mistral_engine, group: mistral-engine }, { name: mistral_executor, group: mistral-executor }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -67,5 +67,5 @@ - [{ name: mistral_api, group: mistral-api }, { name: mistral_engine, group: mistral-engine }, { name: mistral_executor, group: mistral-executor }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/mongodb/tasks/do_reconfigure.yml b/ansible/roles/mongodb/tasks/do_reconfigure.yml index 72f2e6d814..9bec471870 100644 --- a/ansible/roles/mongodb/tasks/do_reconfigure.yml +++ b/ansible/roles/mongodb/tasks/do_reconfigure.yml @@ -43,8 +43,8 @@ - inventory_hostname in groups[item[0]['group']] with_together: - [{ name: mongodb, group: mongodb }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -60,5 +60,5 @@ - inventory_hostname in groups[item[0]['group']] with_together: - [{ name: mongodb, group: mongodb }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/murano/tasks/do_reconfigure.yml b/ansible/roles/murano/tasks/do_reconfigure.yml index 6d777be6db..d5d784aa04 100644 --- a/ansible/roles/murano/tasks/do_reconfigure.yml +++ b/ansible/roles/murano/tasks/do_reconfigure.yml @@ -44,8 +44,8 @@ with_together: - [{ name: murano_api, group: murano-api }, { name: murano_engine, group: murano-engine }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -62,5 +62,5 @@ with_together: - [{ name: murano_api, group: murano-api }, { name: murano_engine, group: murano-engine }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/swift/tasks/do_reconfigure.yml b/ansible/roles/swift/tasks/do_reconfigure.yml index ea97824310..a7922d0792 100644 --- a/ansible/roles/swift/tasks/do_reconfigure.yml +++ b/ansible/roles/swift/tasks/do_reconfigure.yml @@ -107,8 +107,8 @@ { name: swift_object_expirer, group: swift-object-server }, { name: swift_rsyncd, group: swift-object-server }, { name: swift_proxy_server, group: swift-proxy-server }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -140,5 +140,5 @@ { name: swift_object_expirer, group: swift-object-server }, { name: swift_rsyncd, group: swift-object-server }, { name: swift_proxy_server, group: swift-proxy-server }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" diff --git a/ansible/roles/swift/tasks/start.yml b/ansible/roles/swift/tasks/start.yml index 9a2c6bbd7b..891f92ed76 100644 --- a/ansible/roles/swift/tasks/start.yml +++ b/ansible/roles/swift/tasks/start.yml @@ -26,7 +26,7 @@ opts: "noatime,nodiratime,nobarrier,logbufs=8" state: mounted name: "{{ swift_devices_mount_point }}/{{ item['fs_label'] }}" - with_items: swift_disks + with_items: "{{ swift_disks }}" when: inventory_hostname in groups['swift-account-server'] or inventory_hostname in groups['swift-container-server'] or inventory_hostname in groups['swift-object-server'] diff --git a/ansible/roles/watcher/tasks/do_reconfigure.yml b/ansible/roles/watcher/tasks/do_reconfigure.yml index 6f44ef159c..e28ec6ab6f 100644 --- a/ansible/roles/watcher/tasks/do_reconfigure.yml +++ b/ansible/roles/watcher/tasks/do_reconfigure.yml @@ -48,8 +48,8 @@ - [{ name: watcher_api, group: watcher-api }, { name: watcher_engine, group: watcher-engine }, { name: watcher_applier, group: watcher-applier }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}" - include: start.yml when: remove_containers.changed @@ -67,5 +67,5 @@ - [{ name: watcher_api, group: watcher-api }, { name: watcher_engine, group: watcher-engine }, { name: watcher_applier, group: watcher-applier }] - - container_envs.results - - check_results.results + - "{{ container_envs.results }}" + - "{{ check_results.results }}"