]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
nfs: do not copy rgw keyring when `nfs_obj_gw` is true
authorGuillaume Abrioux <gabrioux@redhat.com>
Fri, 7 Aug 2020 08:12:50 +0000 (10:12 +0200)
committerGuillaume Abrioux <gabrioux@redhat.com>
Fri, 7 Aug 2020 11:21:17 +0000 (13:21 +0200)
This keyring shouldn't be copied when `nfs_obj_gw` is `True` if the
cluster doesn't contain a rgw node, which can be the case given we are
using `nfs_obj_gw` instead of `nfs_file_gw` (cephfs vs. object), the
deployment will fail trying to copy a key that doesn't exist.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
roles/ceph-nfs/tasks/pre_requisite_non_container.yml

index 4f9ec79ed80b658c51c66cefcfb3c8cd89fd7b53..4bb4f114c6954a54d02e557f3a488f64270d3970 100644 (file)
@@ -51,7 +51,7 @@
       command: "ceph --cluster {{ cluster }} auth get {{ item.name }}"
       register: _rgw_keys
       with_items:
-        - { name: "client.bootstrap-rgw", path: "/var/lib/ceph/bootstrap-rgw/{{ cluster }}.keyring", copy_key: true }
+        - { name: "client.bootstrap-rgw", path: "/var/lib/ceph/bootstrap-rgw/{{ cluster }}.keyring", copy_key: "{{ nfs_obj_gw }}" }
         - { name: "client.admin", path: "/etc/ceph/{{ cluster }}.client.admin.keyring", copy_key: "{{ copy_admin_key }}" }
       delegate_to: "{{ groups.get(mon_group_name)[0] }}"
       run_once: true