mirror of https://github.com/ceph/ceph-ansible.git
global: make directories mode parameterizable
This commit makes it possible to parametrize the ceph directories modes. So it changes hardocded mode for ceph related directories from 0755 to customizable with `ceph_directories_mode` variable. Closes: #2920 Signed-off-by: Artur Fijalkowski <artur.fijalkowski@ing.com> Co-authored-by: Guillaume Abrioux <gabrioux@redhat.com>pull/4384/head
parent
a0590cae9d
commit
011270ca69
|
@ -72,7 +72,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "ceph"
|
owner: "ceph"
|
||||||
group: "ceph"
|
group: "ceph"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
|
|
||||||
- name: "generate ceph configuration file: {{ cluster }}.conf"
|
- name: "generate ceph configuration file: {{ cluster }}.conf"
|
||||||
action: config_template
|
action: config_template
|
||||||
|
@ -98,7 +98,7 @@
|
||||||
file:
|
file:
|
||||||
path: "{{ fetch_directory }}/{{ fsid }}/etc/ceph"
|
path: "{{ fetch_directory }}/{{ fsid }}/etc/ceph"
|
||||||
state: directory
|
state: directory
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
delegate_to: localhost
|
delegate_to: localhost
|
||||||
when: ceph_conf_local | bool
|
when: ceph_conf_local | bool
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
with_items:
|
with_items:
|
||||||
- /var/lib/ceph/bootstrap-mds/
|
- /var/lib/ceph/bootstrap-mds/
|
||||||
- /var/lib/ceph/mds/{{ cluster }}-{{ mds_name }}
|
- /var/lib/ceph/mds/{{ cluster }}-{{ mds_name }}
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
|
|
||||||
- name: fetch ceph mgr keyring
|
- name: fetch ceph mgr keyring
|
||||||
ceph_key:
|
ceph_key:
|
||||||
|
|
|
@ -56,7 +56,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "u=rwX,g=rX,o=rX"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
recurse: true
|
recurse: true
|
||||||
|
|
||||||
- name: create custom admin keyring
|
- name: create custom admin keyring
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "ceph"
|
owner: "ceph"
|
||||||
group: "ceph"
|
group: "ceph"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
with_items:
|
with_items:
|
||||||
- { name: "/var/lib/ceph/bootstrap-rgw", create: "{{ nfs_obj_gw }}" }
|
- { name: "/var/lib/ceph/bootstrap-rgw", create: "{{ nfs_obj_gw }}" }
|
||||||
- { name: "/var/lib/ceph/radosgw", create: "{{ nfs_obj_gw }}" }
|
- { name: "/var/lib/ceph/radosgw", create: "{{ nfs_obj_gw }}" }
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
when: cephx | bool
|
when: cephx | bool
|
||||||
with_items:
|
with_items:
|
||||||
- /var/lib/ceph/bootstrap-osd/
|
- /var/lib/ceph/bootstrap-osd/
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
with_items: "{{ rbd_client_admin_socket_path }}"
|
with_items: "{{ rbd_client_admin_socket_path }}"
|
||||||
|
|
||||||
- name: create rados gateway instance directories
|
- name: create rados gateway instance directories
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
owner: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
group: "{{ ceph_uid if containerized_deployment else 'ceph' }}"
|
||||||
mode: "0755"
|
mode: "{{ ceph_directories_mode | default('0755') }}"
|
||||||
with_items: "{{ rgw_instances }}"
|
with_items: "{{ rgw_instances }}"
|
||||||
when: rgw_instances is defined
|
when: rgw_instances is defined
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue