From e2cbffc1c747be4c50446a7aed73da4e5d84b82e Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Tue, 13 Feb 2024 00:48:13 +0100 Subject: [PATCH] drop variables from 'hosts' key The linter complains about that. It doesn't work anyway so it doesn't make sense to leave these variables here. Signed-off-by: Guillaume Abrioux --- infrastructure-playbooks/shrink-mds.yml | 4 ++-- infrastructure-playbooks/shrink-mgr.yml | 4 ++-- infrastructure-playbooks/shrink-mon.yml | 4 ++-- infrastructure-playbooks/shrink-osd.yml | 6 +++--- infrastructure-playbooks/shrink-rbdmirror.yml | 6 +++--- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/infrastructure-playbooks/shrink-mds.yml b/infrastructure-playbooks/shrink-mds.yml index 296ef52f1f..04b8e1daa8 100644 --- a/infrastructure-playbooks/shrink-mds.yml +++ b/infrastructure-playbooks/shrink-mds.yml @@ -24,7 +24,7 @@ tasks_from: container_binary - name: perform checks, remove mds and print cluster health - hosts: "{{ groups[mon_group_name][0] }}" + hosts: mons[0] become: true vars_prompt: - name: ireallymeanit @@ -165,4 +165,4 @@ post_tasks: - name: show ceph health command: "{{ container_exec_cmd | default('') }} ceph --cluster {{ cluster }} -s" - changed_when: false \ No newline at end of file + changed_when: false diff --git a/infrastructure-playbooks/shrink-mgr.yml b/infrastructure-playbooks/shrink-mgr.yml index 66745f7c60..378ab661a4 100644 --- a/infrastructure-playbooks/shrink-mgr.yml +++ b/infrastructure-playbooks/shrink-mgr.yml @@ -21,7 +21,7 @@ msg: gather facts on all Ceph hosts for following reference - name: confirm if user really meant to remove manager from the ceph cluster - hosts: "{{ groups[mon_group_name][0] }}" + hosts: mons[0] become: true vars_prompt: - name: ireallymeanit @@ -130,4 +130,4 @@ post_tasks: - name: show ceph health command: "{{ container_exec_cmd | default('') }} ceph --cluster {{ cluster }} -s" - changed_when: false \ No newline at end of file + changed_when: false diff --git a/infrastructure-playbooks/shrink-mon.yml b/infrastructure-playbooks/shrink-mon.yml index 05d6c2be54..1bf1f7c46a 100644 --- a/infrastructure-playbooks/shrink-mon.yml +++ b/infrastructure-playbooks/shrink-mon.yml @@ -22,7 +22,7 @@ - debug: msg="gather facts on all Ceph hosts for following reference" - name: confirm whether user really meant to remove monitor from the ceph cluster - hosts: "{{ groups[mon_group_name][0] }}" + hosts: mons[0] become: true vars_prompt: - name: ireallymeanit @@ -144,4 +144,4 @@ - name: show ceph mon status command: "{{ container_exec_cmd }} ceph --cluster {{ cluster }} mon stat" delegate_to: "{{ mon_host }}" - changed_when: false \ No newline at end of file + changed_when: false diff --git a/infrastructure-playbooks/shrink-osd.yml b/infrastructure-playbooks/shrink-osd.yml index 2d3f3639fd..09573da8bc 100644 --- a/infrastructure-playbooks/shrink-osd.yml +++ b/infrastructure-playbooks/shrink-osd.yml @@ -14,8 +14,8 @@ - name: gather facts and check the init system hosts: - - "{{ mon_group_name|default('mons') }}" - - "{{ osd_group_name|default('osds') }}" + - mons + - osds become: True tasks: @@ -23,7 +23,7 @@ - name: confirm whether user really meant to remove osd(s) from the cluster - hosts: "{{ groups[mon_group_name][0] }}" + hosts: mons[0] become: true diff --git a/infrastructure-playbooks/shrink-rbdmirror.yml b/infrastructure-playbooks/shrink-rbdmirror.yml index db7cc3a213..79f8327d0c 100644 --- a/infrastructure-playbooks/shrink-rbdmirror.yml +++ b/infrastructure-playbooks/shrink-rbdmirror.yml @@ -13,8 +13,8 @@ - name: gather facts and check the init system hosts: - - "{{ mon_group_name|default('mons') }}" - - "{{ mon_group_name|default('rbdmirrors') }}" + - mons + - rbdmirrors become: true tasks: - debug: @@ -22,7 +22,7 @@ - name: confirm whether user really meant to remove rbd mirror from the ceph cluster - hosts: "{{ groups[mon_group_name][0] }}" + hosts: mons[0] become: true vars_prompt: - name: ireallymeanit