Set context on /srv/web

Signed-off-by: Patrick Uiterwijk <puiterwijk@redhat.com>
This commit is contained in:
Patrick Uiterwijk 2015-07-08 23:02:15 +00:00
parent 302470d26b
commit 6b813e7b36

View file

@ -96,6 +96,21 @@
- config
- selinux
- name: check the selinux context of the web dir
command: matchpathcon "/srv/web(/.*)?"
register: gitcontext
always_run: yes
changed_when: false
tags:
- config
- selinux
- name: set the SELinux policy for the web dir
command: semanage fcontext -a -t httpd_sys_content_t "/srv/web(/.*)?"
when: gitcontext.stdout.find('httpd_sys_content_t') == -1
tags:
- config
- selinux
#
# This sets the default, it's safe to always run.
# Default quota for users is 2gb