rolling_update: get fsid in mgr pre_task

{{ fsid }} points to {{ cluster_uuid.stdout }} which is not defined in
this part of the rolling_update playbook.
Since we need to call {{ fsid }} we must get the fsid and register it to
`cluster_uuid`.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
pull/2589/head
Guillaume Abrioux 2018-05-11 08:05:11 +02:00
parent 52fc8a0385
commit 3b89f1bfb1
1 changed files with 5 additions and 0 deletions

View File

@ -192,6 +192,11 @@
become: True become: True
pre_tasks: pre_tasks:
- name: get current fsid
command: "ceph --cluster {{ cluster }} fsid"
register: cluster_uuid
delegate_to: "{{ groups[mon_group_name][0] }}"
- name: non container | create ceph mgr keyring(s) - name: non container | create ceph mgr keyring(s)
command: "ceph --cluster {{ cluster }} auth get-or-create mgr.{{ hostvars[item]['ansible_hostname'] }} mon 'allow profile mgr' osd 'allow *' mds 'allow *' -o /etc/ceph/{{ cluster }}.mgr.{{ hostvars[item]['ansible_hostname'] }}.keyring" command: "ceph --cluster {{ cluster }} auth get-or-create mgr.{{ hostvars[item]['ansible_hostname'] }} mon 'allow profile mgr' osd 'allow *' mds 'allow *' -o /etc/ceph/{{ cluster }}.mgr.{{ hostvars[item]['ansible_hostname'] }}.keyring"
args: args: