diff --git a/roles/ceph-mgr/tasks/main.yml b/roles/ceph-mgr/tasks/main.yml index f017f8892..e578e2017 100644 --- a/roles/ceph-mgr/tasks/main.yml +++ b/roles/ceph-mgr/tasks/main.yml @@ -17,6 +17,8 @@ command: "{{ docker_exec_cmd_mgr | default('') }} ceph --cluster {{ cluster }} --format json mgr module ls" register: enabled_ceph_mgr_modules delegate_to: "{{ groups[mon_group_name][0] }}" + when: + - ceph_release_num[ceph_release] >= ceph_release_num['luminous'] - name: disable ceph mgr enabled modules command: "{{ docker_exec_cmd_mgr | default('') }} ceph --cluster {{ cluster }} mgr module disable {{ item }}" @@ -26,8 +28,11 @@ delegate_to: "{{ groups[mon_group_name][0] }}" when: - not enabled_ceph_mgr_modules.get('skipped') + - ceph_release_num[ceph_release] >= ceph_release_num['luminous'] - name: add modules to ceph-mgr command: "{{ docker_exec_cmd_mgr | default('') }} ceph --cluster {{ cluster }} mgr module enable {{ item }}" with_items: "{{ ceph_mgr_modules }}" delegate_to: "{{ groups[mon_group_name][0] }}" + when: + - ceph_release_num[ceph_release] >= ceph_release_num['luminous']