Skip to content

Commit cc0c7b0

Browse files
committed
local policy
1 parent 5aa1bfe commit cc0c7b0

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tasks/prerequisites/setup-selinux.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,16 @@
8282
- name: "(Install: SELinux: Contexts) Apply contexts to log"
8383
command: restorecon -iRv /var/log/app_protect
8484

85+
- name: "(Install: SELinux: Custom) Generate policy"
86+
shell:
87+
args:
88+
chdir: /tmp/
89+
executable: bash
90+
cmd: cat /var/log/audit/audit.log | audit2allow -M local
91+
92+
- name: "(Install: SELinux: Custom) Apply local policy"
93+
command: semodule -i /tmp/local.pp
94+
8595
- name: "(Install: SELinux: Custom) Copy custom policy"
8696
copy:
8797
src: "{{ role_path }}/files/my-appprotect.te"

0 commit comments

Comments
 (0)