Refactor AIDE configuration and add exclusion paths

This commit is contained in:
2024-10-05 21:19:51 +02:00
parent 9c02c2b839
commit 90852bb9a6
13 changed files with 47 additions and 22 deletions
+10
View File
@@ -0,0 +1,10 @@
install_aide: true
aide_exclude: []
_default_aide_exclude:
- "!/var/lib/docker"
- "!/var/lib/lxcfs"
- "!/var/lib/private/systemd"
- "!/var/log/audit"
- "!/var/log/journal"
_aide_exclude: "{{ _default_aide_exclude + aide_exclude }}"
-1
View File
@@ -1,5 +1,4 @@
---
install_aide: false
reboot_ubuntu: false
redhat_signing_keys:
- 567E347AD0044ADE55BA8A5F199E2F91FD431D51
+3 -5
View File
@@ -69,11 +69,9 @@
backup: true
insertafter: EOF
block: |
!/var/lib/docker
!/var/lib/lxcfs
!/var/lib/private/systemd
!/var/log/audit
!/var/log/journal
{% for exclude in _aide_exclude %}
{{ exclude }}
{% endfor %}
when: ansible_os_family == "Debian"
tags:
- aide
+7
View File
@@ -221,6 +221,13 @@
tags:
- roles::cis::extras
- name: Configure aide
ansible.builtin.include_tasks: aide.yml
when: install_aide
tags:
- roles::cis::aide
- name: Miscellaneous tasks after all handlers
ansible.builtin.include_tasks: post.yml
tags: