Replace this with a hopefully much faster version.
This commit is contained in:
parent
9a710f3b45
commit
d1441d3d99
1 changed files with 17 additions and 4 deletions
|
@ -64,11 +64,24 @@
|
|||
tags:
|
||||
- httpd
|
||||
- httpd/website
|
||||
- name: ..and apply the httpd_sys_content_t type recursively to it.
|
||||
file: >
|
||||
dest=/srv/web state=directory
|
||||
setype=httpd_sys_content_t recurse=True
|
||||
|
||||
- name: check the selinux context of webdir
|
||||
command: matchpathcon /srv/web
|
||||
register: webdir
|
||||
always_run: yes
|
||||
changed_when: "1 != 1"
|
||||
tags:
|
||||
- config
|
||||
- selinux
|
||||
- httpd
|
||||
- httpd/website
|
||||
|
||||
- name: /srv/web file contexts
|
||||
command: semanage fcontext -a -t httpd_sys_content_t "/srv/web(/.*)?"
|
||||
when: webdir.stdout.find('httpd_sys_content_t') == -1
|
||||
tags:
|
||||
- config
|
||||
- selinux
|
||||
- httpd
|
||||
- httpd/website
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue