- "restart ceph rbdmirrors"
- "restart ceph mgrs"
register: tmpdirpath
- when: tmpdirpath is defined
+ when: tmpdirpath.path is defined
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph mds daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_mds_daemon.sh
when:
- hostvars[item]['handler_mds_status'] | default(False) | bool
- hostvars[item]['_mds_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[mds_group_name] }}"
delegate_to: "{{ item }}"
run_once: True
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph mgr daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_mgr_daemon.sh
when:
- hostvars[item]['handler_mgr_status'] | default(False) | bool
- hostvars[item]['_mgr_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[mgr_group_name] }}"
delegate_to: "{{ item }}"
run_once: True
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph mon daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_mon_daemon.sh
# We do not want to run these checks on initial deployment (`socket.rc == 0`)
- hostvars[item]['handler_mon_status'] | default(False) | bool
- hostvars[item]['_mon_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[mon_group_name] }}"
delegate_to: "{{ item }}"
run_once: True
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph nfs daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_nfs_daemon.sh
when:
- hostvars[item]['handler_nfs_status'] | default(False) | bool
- hostvars[item]['_nfs_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[nfs_group_name] }}"
delegate_to: "{{ item }}"
run_once: True
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: get pool list
command: "{{ ceph_cmd }} --cluster {{ cluster }} osd pool ls detail -f json"
- hostvars[item]['handler_osd_status'] | default(False) | bool
- handler_health_osd_check | bool
- hostvars[item]['_osd_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[osd_group_name] | intersect(ansible_play_batch) }}"
delegate_to: "{{ item }}"
run_once: True
run_once: true
delegate_to: "{{ groups[mon_group_name][0] }}"
changed_when: false
- when: (balancer_status.stdout | from_json)['active'] | bool
\ No newline at end of file
+ when: (balancer_status.stdout | from_json)['active'] | bool
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph rbd mirror daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_rbd_mirror_daemon.sh
when:
- hostvars[item]['handler_rbd_mirror_status'] | default(False) | bool
- hostvars[item]['_rbdmirror_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[rbdmirror_group_name] }}"
delegate_to: "{{ item }}"
run_once: True
owner: root
group: root
mode: 0750
+ when: tmpdirpath.path is defined
- name: restart ceph rgw daemon(s)
command: /usr/bin/env bash {{ hostvars[item]['tmpdirpath']['path'] }}/restart_rgw_daemon.sh
when:
- hostvars[item]['handler_rgw_status'] | default(False) | bool
- hostvars[item]['_rgw_handler_called'] | default(False) | bool
+ - hostvars[item].tmpdirpath.path is defined
with_items: "{{ groups[rgw_group_name] }}"
delegate_to: "{{ item }}"
run_once: True