Add proper permission for selinux

Signed-off-by: Sébastien Han <seb@redhat.com>
pull/426/head
Sébastien Han 2015-10-21 12:02:50 +02:00
parent 29d38c6038
commit 9264a868fd
8 changed files with 64 additions and 0 deletions

View File

@ -9,5 +9,8 @@
when: ceph_health.rc != 0 when: ceph_health.rc != 0
- include: pre_requisite.yml - include: pre_requisite.yml
- include: selinux.yml
when: ansible_os_family == 'RedHat'
- include: fetch_configs.yml - include: fetch_configs.yml
- include: start_docker_mds.yml - include: start_docker_mds.yml

View File

@ -0,0 +1,13 @@
---
- name: check if selinux is enabled
command: getenforce
register: sestatus
changed_when: false
- name: set selinux permissions
shell: chcon -Rt svirt_sandbox_file_t {{ item }}
with_items:
- /etc/ceph
- /var/lib/ceph
changed_when: false
when: sestatus.stdout != 'Disabled'

View File

@ -9,6 +9,9 @@
when: ceph_health.rc != 0 when: ceph_health.rc != 0
- include: pre_requisite.yml - include: pre_requisite.yml
- include: selinux.yml
when: ansible_os_family == 'RedHat'
- include: fetch_configs.yml - include: fetch_configs.yml
- include: start_docker_monitor.yml - include: start_docker_monitor.yml
- include: copy_configs.yml - include: copy_configs.yml

View File

@ -0,0 +1,13 @@
---
- name: check if selinux is enabled
command: getenforce
register: sestatus
changed_when: false
- name: set selinux permissions
shell: chcon -Rt svirt_sandbox_file_t {{ item }}
with_items:
- /etc/ceph
- /var/lib/ceph
changed_when: false
when: sestatus.stdout != 'Disabled'

View File

@ -9,5 +9,8 @@
when: ceph_health.rc != 0 when: ceph_health.rc != 0
- include: pre_requisite.yml - include: pre_requisite.yml
- include: selinux.yml
when: ansible_os_family == 'RedHat'
- include: fetch_configs.yml - include: fetch_configs.yml
- include: start_docker_osd.yml - include: start_docker_osd.yml

View File

@ -0,0 +1,13 @@
---
- name: check if selinux is enabled
command: getenforce
register: sestatus
changed_when: false
- name: set selinux permissions
shell: chcon -Rt svirt_sandbox_file_t {{ item }}
with_items:
- /etc/ceph
- /var/lib/ceph
changed_when: false
when: sestatus.stdout != 'Disabled'

View File

@ -9,5 +9,8 @@
when: ceph_health.rc != 0 when: ceph_health.rc != 0
- include: pre_requisite.yml - include: pre_requisite.yml
- include: selinux.yml
when: ansible_os_family == 'RedHat'
- include: fetch_configs.yml - include: fetch_configs.yml
- include: start_docker_rgw.yml - include: start_docker_rgw.yml

View File

@ -0,0 +1,13 @@
---
- name: check if selinux is enabled
command: getenforce
register: sestatus
changed_when: false
- name: set selinux permissions
shell: chcon -Rt svirt_sandbox_file_t {{ item }}
with_items:
- /etc/ceph
- /var/lib/ceph
changed_when: false
when: sestatus.stdout != 'Disabled'