From 3b1794a0fd7ad7f4fe3c3a7a586cbda2f4d484be Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Mon, 9 Dec 2019 14:20:42 +0100 Subject: [PATCH] switch_to_containers: exclude clients nodes from facts gathering just like site.yml and rolling_update, let's exclude clients node from the fact gathering. Signed-off-by: Guillaume Abrioux (cherry picked from commit 332c39376b45375a2c0566406b49896ae316a293) (cherry picked from commit 5c3ba0787cf346c7e5eb5df74a1da4984c16e7aa) --- ...-containerized-to-containerized-ceph-daemons.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml b/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml index b49e93946..c96c2d08b 100644 --- a/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml +++ b/infrastructure-playbooks/switch-from-non-containerized-to-containerized-ceph-daemons.yml @@ -39,12 +39,21 @@ become: true - tasks: + vars: + delegate_facts_host: True + + roles: + - ceph-defaults + + post_tasks: - name: gather and delegate facts setup: delegate_to: "{{ item }}" delegate_facts: True - with_items: "{{ groups['all'] }}" + with_items: "{{ groups['all'] | difference(groups.get(client_group_name, [])) }}" + run_once: true + when: delegate_facts_host | bool + tags: always - name: switching from non-containerized to containerized ceph mon -- 2.39.5