there is no need to use `shell` in these tasks. Let's use `command`.
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
- not rolling_update | bool
block:
- name: generate cluster fsid
- shell: "{{ discovered_interpreter_python }} -c 'import uuid; print(str(uuid.uuid4()))'"
+ command: "{{ discovered_interpreter_python }} -c 'import uuid; print(str(uuid.uuid4()))'"
register: cluster_uuid
delegate_to: "{{ groups[mon_group_name][0] }}"
run_once: true
when: ceph_current_status.fsid is defined
- name: generate monitor initial keyring
- shell: >
+ command: >
{{ discovered_interpreter_python }} -c "import os ; import struct ;
import time; import base64 ; key = os.urandom(16) ;
header = struct.pack('<hiih',1,int(time.time()),0,len(key)) ;