Fix undefined running_mon

Since commit [1] running_mon introduced, it can be not defined
which results in fatal error [2]. This patch defines default value which
was used before patch [1]

Signed-off-by: Dmitriy Rabotyagov <drabotyagov@vexxhost.com>

[1] 8dcbcecd71
[2] https://zuul.opendev.org/t/openstack/build/c82a73aeabd64fd583694ed04b947731/log/job-output.txt#14011

(cherry picked from commit 2478a7b948)
pull/4961/head
Dmitriy Rabotyagov 2020-01-16 20:23:58 +02:00 committed by Dimitri Savineau
parent cae24dd85a
commit 8d311a537d
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@
command: "{{ _container_exec_cmd | default('') }} ceph --cluster {{ cluster }} auth get {{ item.name }}" command: "{{ _container_exec_cmd | default('') }} ceph --cluster {{ cluster }} auth get {{ item.name }}"
register: _mgr_keys register: _mgr_keys
with_items: "{{ _mgr_keys }}" with_items: "{{ _mgr_keys }}"
delegate_to: "{{ running_mon }}" delegate_to: "{{ groups[mon_group_name][0] if running_mon is undefined else running_mon }}"
when: when:
- cephx | bool - cephx | bool
- item.copy_key | bool - item.copy_key | bool