ansible-ppm/roles/ppm/tasks/firewall.yml
Peter 242a6d1cca new firewall system
Render the template system wide, then apply.  This way, the
appdefinition.yml can contain everything that is required, and we don't
have to specify this anymore in the main config
2025-07-14 18:35:05 +02:00

13 lines
452 B
YAML

- name: Configure firewall options
ansible.builtin.copy:
dest: /home/.ppmfirewalltemplate
group: root
owner: root
mode: "0755"
src: ppmfirewall
- name: Render firewall
ansible.builtin.shell: ppm template /home/.ppmfirewalltemplate /etc/firewall.d/ppmfirewall ; chmod 755 /etc/firewall.d/ppmfirewall
register: firewall_render
changed_when: "'content did not change' not in firewall_render.stdout"
notify: Restart firewall