dashboard: if no host is available, let's just skip these plays.

If there is no host available, let's just skip these plays.

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

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
pull/4582/head
Guillaume Abrioux 2019-10-09 14:46:43 +02:00 committed by Dimitri Savineau
parent 4bba1d0fc5
commit 0b245bd007
1 changed files with 3 additions and 1 deletions

View File

@ -65,7 +65,9 @@
status: "Complete"
end: "{{ lookup('pipe', 'date +%Y%m%d%H%M%SZ') }}"
- hosts: "{{ groups[mgr_group_name] | default(groups[mon_group_name]) }}"
# using groups[] here otherwise it can't fallback to the mon if there's no mgr group.
# adding an additional | default(omit) in case where no monitors are present (external ceph cluster)
- hosts: "{{ groups[mgr_group_name] | default(groups[mon_group_name]) | default(omit) }}"
become: true
pre_tasks:
- name: set ceph dashboard install 'In Progress'