switch2container: fix mon quorum check

The current check makes no sense because it checks any of other monitor
than the one being played (either a previous one already converted or a
next that isn't yet converted) is present on the quorum.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1909011

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit 175ffa1b88)
pull/6186/head
Guillaume Abrioux 2020-12-18 10:33:44 +01:00 committed by Dimitri Savineau
parent 54f7983be2
commit 8d59a25a55
1 changed files with 2 additions and 3 deletions

View File

@ -135,11 +135,10 @@
post_tasks: post_tasks:
- name: waiting for the monitor to join the quorum... - name: waiting for the monitor to join the quorum...
command: "{{ container_exec_cmd }} ceph --cluster {{ cluster }} quorum_status --format json" command: "{{ container_binary }} run --rm -v /etc/ceph:/etc/ceph:z --entrypoint=ceph {{ ceph_docker_registry }}/{{ ceph_docker_image }}:{{ ceph_docker_image_tag }} --cluster {{ cluster }} quorum_status --format json"
register: ceph_health_raw register: ceph_health_raw
until: ansible_hostname in (ceph_health_raw.stdout | trim | from_json)["quorum_names"]
changed_when: false changed_when: false
until: >
hostvars[mon_host]['ansible_hostname'] in (ceph_health_raw.stdout | from_json)["quorum_names"]
retries: "{{ health_mon_check_retries }}" retries: "{{ health_mon_check_retries }}"
delay: "{{ health_mon_check_delay }}" delay: "{{ health_mon_check_delay }}"