Skip to content

Commit

Permalink
adopt: fix bug in mon_ip_list set_fact
Browse files Browse the repository at this point in the history
`default('{}')` must be before `| from_json`

Signed-off-by: Guillaume Abrioux <[email protected]>
  • Loading branch information
guits committed Feb 9, 2022
1 parent ddae06e commit f307674
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion infrastructure-playbooks/cephadm-adopt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@
- name: set_fact mon_ip_list
set_fact:
mon_ip_list: "{{ mon_ip_list | default([]) | union([item['addr'].split(':')[0]]) }}"
loop: "{{ (quorum_status.stdout | from_json | default('{}'))['monmap']['mons'] }}"
loop: "{{ (quorum_status.stdout | default('{}') | from_json)['monmap']['mons'] }}"
run_once: true

- name: remove current mirror peer
Expand Down

0 comments on commit f307674

Please sign in to comment.