2022-06-13 18:47:12 +00:00
|
|
|
---
|
2022-10-17 06:47:09 +00:00
|
|
|
- include_tasks: setup.yml
|
|
|
|
when: firewalld_enabled | bool
|
|
|
|
|
|
|
|
- name: Ensure service has expected state
|
|
|
|
service:
|
|
|
|
name: firewalld
|
|
|
|
daemon_reload: True
|
|
|
|
enabled: "{{ firewalld_enabled | bool }}"
|
|
|
|
masked: "{{ not firewalld_enabled | bool }}"
|
|
|
|
state: "{{ firewalld_enabled | bool | ternary('started', 'stopped', 'started') }}"
|
2022-10-12 07:59:13 +00:00
|
|
|
become: True
|
|
|
|
become_user: root
|