Merge "Add mon address to ceph release version check"

This commit is contained in:
Zuul 2019-08-06 17:04:13 +00:00 committed by Gerrit Code Review
commit 3731da0b79

View File

@ -3,7 +3,7 @@
- name: Check final release (as running on MONs) - name: Check final release (as running on MONs)
become: true become: true
shell: docker exec ceph_mon ceph version | cut -d' ' -f5 command: "docker exec ceph_mon ceph -m {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4']['address'] }} versions"
changed_when: false changed_when: false
register: ceph_release_command register: ceph_release_command
delegate_to: "{{ groups['ceph-mon'][0] }}" delegate_to: "{{ groups['ceph-mon'][0] }}"
@ -11,7 +11,7 @@
- name: Finalize the upgrade by disallowing older OSDs - name: Finalize the upgrade by disallowing older OSDs
become: true become: true
command: docker exec ceph_mon ceph osd require-osd-release {{ ceph_release_command.stdout }} command: "docker exec ceph_mon ceph -m {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4']['address'] }} osd require-osd-release {{ ((ceph_release_command.stdout|from_json).mon | string).split(' ')[4] }}"
changed_when: false changed_when: false
delegate_to: "{{ groups['ceph-mon'][0] }}" delegate_to: "{{ groups['ceph-mon'][0] }}"
run_once: true run_once: true