split notify, add tmp options for arch

Signed-off-by: Martin Schurz <Martin.Schurz@telekom.de>
This commit is contained in:
Martin Schurz 2023-11-21 21:58:58 +01:00
parent 60d10811d4
commit 20dd04c9cb
3 changed files with 11 additions and 6 deletions

View file

@ -12,6 +12,9 @@
- name: override for arch
set_fact:
os_mnt_boot_enabled: false
os_mnt_tmp_enabled: true
os_mnt_tmp_src: "tmpfs"
os_mnt_tmp_filesystem: "tmpfs"
when: ansible_facts.os_family == 'Archlinux'
- name: overrides for Fedora image
set_fact:

View file

@ -2,18 +2,18 @@
- name: Update-initramfs # noqa no-changed-when
ansible.builtin.command: update-initramfs -u
- name: Restart auditd
- name: Restart auditd via systemd
ansible.builtin.systemd:
name: auditd
state: restarted
when:
- molecule_yml.driver.name | default() != "docker" # restarting auditd in a container does not
when:
- molecule_yml.driver.name | default() != "docker" # restarting auditd in a container does not work
- not ansible_facts.os_family == 'RedHat'
- name: Restart auditd # noqa command-instead-of-module no-changed-when
- name: Restart auditd via service # noqa command-instead-of-module no-changed-when
ansible.builtin.command:
cmd: service auditd restart # rhel: see: https://access.redhat.com/solutions/2664811
when:
when:
- molecule_yml.driver.name | default() != "docker" # restarting auditd in a container does not work
- ansible_facts.os_family == 'RedHat'

View file

@ -12,5 +12,7 @@
owner: root
group: root
mode: "0640"
notify: Restart auditd
notify:
- Restart auditd via service
- Restart auditd via systemd
tags: auditd