refactor(standardize): fix sudoers lecture syntax, extract ssh config, remove redundant os filters

This commit is contained in:
2026-02-13 00:20:59 +01:00
parent af5eecfc01
commit eeb580f180
17 changed files with 67 additions and 62 deletions

View File

@@ -1,6 +1,6 @@
---
- name: Enable Systemd Services
when: os | lower not in ['alpine', 'void']
when: os not in ['alpine', 'void']
ansible.builtin.command: >
{{ chroot_command }} systemctl enable NetworkManager
{{ ' firewalld' if system_cfg.features.firewall.backend == 'firewalld' and system_cfg.features.firewall.enabled | bool else '' }}
@@ -11,13 +11,13 @@
}}
{{
'logrotate systemd-resolved systemd-timesyncd systemd-networkd'
if os | lower == 'archlinux' else ''
if os == 'archlinux' else ''
}}
register: configuration_enable_services_result
changed_when: configuration_enable_services_result.rc == 0
- name: Enable OpenRC services
when: os | lower == 'alpine'
when: os == 'alpine'
vars:
configuration_openrc_services: >-
{{
@@ -48,7 +48,7 @@
when: item.stat.exists
- name: Enable runit services
when: os | lower == 'void'
when: os == 'void'
vars:
configuration_runit_services: >-
{{