From: Guits Date: Wed, 8 Feb 2017 09:45:09 +0000 (+0100) Subject: ceph-mon: Fix bug #1242 X-Git-Tag: v2.2.0rc1~37^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=df162a61b198aa629bfdb6b718d783a357b70665;p=ceph-ansible.git ceph-mon: Fix bug #1242 We shouldn't test directly the value of `ceph_conf_overrides.global.osd_pool_default_pg_num` because this can cause the playbook to fail if the key `global` is not present in `ceph_conf_overrides`. Therefore we have to use the facts that have been defined earlier. Fix: #1242 Signed-off-by: Guillaume Abrioux --- diff --git a/roles/ceph-mon/tasks/ceph_keys.yml b/roles/ceph-mon/tasks/ceph_keys.yml index f58c8b7fb..3986661a3 100644 --- a/roles/ceph-mon/tasks/ceph_keys.yml +++ b/roles/ceph-mon/tasks/ceph_keys.yml @@ -73,7 +73,7 @@ when: - pool_default_pg_num is not defined - default_pool_default_pg_num.rc == 0 - - ceph_conf_overrides.global.osd_pool_default_pg_num is not defined + - (osd_pool_default_pg_num_in_overrides is not defined or not osd_pool_default_pg_num_in_overrides) - set_fact: osd_pool_default_pg_num: "{{ ceph_conf_overrides.global.osd_pool_default_pg_num }}"