mirror of
https://github.com/ansible-lockdown/RHEL9-CIS.git
synced 2025-12-24 22:23:06 +00:00
lint and var renaming
Signed-off-by: Mark Bolwell <mark.bollyuk@gmail.com>
This commit is contained in:
parent
fa13b06b1f
commit
879d9c9a1b
18 changed files with 84 additions and 86 deletions
|
|
@ -3,7 +3,7 @@
|
|||
- name: POST | AUDITD | Apply auditd template will for section 4.1.3 - only required rules will be added | stat file
|
||||
ansible.builtin.stat:
|
||||
path: /etc/audit/rules.d/99_auditd.rules
|
||||
register: rhel9cis_auditd_file
|
||||
register: discovered_auditd_rules_file
|
||||
|
||||
- name: POST | AUDITD | Apply auditd template will for section 4.1.3 - only required rules will be added | setup file
|
||||
ansible.builtin.template:
|
||||
|
|
@ -12,8 +12,8 @@
|
|||
owner: root
|
||||
group: root
|
||||
mode: '0640'
|
||||
diff: "{{ rhel9cis_auditd_file.stat.exists }}" # Only run diff if not a new file
|
||||
register: rhel9cis_auditd_template_updated
|
||||
diff: "{{ discovered_auditd_rules_file.stat.exists }}" # Only run diff if not a new file
|
||||
register: discovered_auditd_rules_template_updated
|
||||
notify:
|
||||
- Auditd immutable check
|
||||
- Audit immutable fact
|
||||
|
|
@ -21,8 +21,8 @@
|
|||
|
||||
- name: POST | AUDITD | Add Warning count for changes to template file | Warn Count # noqa no-handler
|
||||
when:
|
||||
- rhel9cis_auditd_template_updated.changed
|
||||
- rhel9cis_auditd_file.stat.exists
|
||||
- discovered_auditd_rules_template_updated.changed
|
||||
- discovered_auditd_rules_file.stat.exists
|
||||
ansible.builtin.import_tasks:
|
||||
file: warning_facts.yml
|
||||
vars:
|
||||
|
|
@ -31,7 +31,7 @@
|
|||
- name: POST | AUDITD | Apply auditd template will for section 4.1.3 - only required rules will be added | stat file
|
||||
ansible.builtin.stat:
|
||||
path: /etc/audit/rules.d/98_auditd_exceptions.rules
|
||||
register: rhel9cis_auditd_exception_file
|
||||
register: discovered_auditd_exception_file
|
||||
|
||||
- name: POST | Set up auditd user logging exceptions | setup file
|
||||
when:
|
||||
|
|
@ -43,5 +43,5 @@
|
|||
owner: root
|
||||
group: root
|
||||
mode: '0640'
|
||||
diff: "{{ rhel9cis_auditd_exception_file.stat.exists }}"
|
||||
diff: "{{ discovered_auditd_exception_file.stat.exists }}"
|
||||
notify: Restart auditd
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue