Add host exclusion and improve UFW task reliability

Add `excluded` host group and skip offline hosts
Fix UFW service initialization command for Alpine Linux
This commit is contained in:
Damien
2026-06-13 10:17:13 +02:00
parent 77869f0e50
commit c86df61152
3 changed files with 20 additions and 6 deletions

View File

@@ -17,7 +17,7 @@
- name: Add UFW to default runlevel (Alpine)
ansible.builtin.command:
cmd: rc-update add ufw default
cmd: /sbin/rc-update add ufw default
register: ufw_rc_update_result
changed_when: >- # " >- : transform multiple lines into one line"
'already' not in ufw_rc_update_result.stdout