2022-06-13 18:47:12 +00:00
|
|
|
---
|
2024-08-19 14:06:02 +00:00
|
|
|
- name: Configure firewalld
|
|
|
|
ansible.builtin.include_tasks: firewalld.yml
|
|
|
|
when: firewalld_enabled | bool
|
2022-10-17 06:47:09 +00:00
|
|
|
|
|
|
|
- name: Ensure service has expected state
|
2024-02-18 11:32:10 +00:00
|
|
|
ansible.builtin.service:
|
2022-10-17 06:47:09 +00:00
|
|
|
name: firewalld
|
|
|
|
daemon_reload: True
|
|
|
|
enabled: "{{ firewalld_enabled | bool }}"
|
|
|
|
masked: "{{ not firewalld_enabled | bool }}"
|
|
|
|
state: "{{ firewalld_enabled | bool | ternary('started', 'stopped', 'started') }}"
|