change the restart, it was not effective beforetags/v0.6.2
- require: | - require: | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
config_firewalld: | config_firewalld: | ||||
file.managed: | file.managed: | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- file: directory_firewalld | - file: directory_firewalld | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
pkg.installed: | pkg.installed: | ||||
- name: {{ firewalld.package }} | - name: {{ firewalld.package }} | ||||
service_firewalld: | |||||
service_firewalld_running: | |||||
service.running: | service.running: | ||||
- name: {{ firewalld.service }} | - name: {{ firewalld.service }} | ||||
- enable: True # start on boot | - enable: True # start on boot | ||||
- file: config_firewalld | - file: config_firewalld | ||||
- service: iptables # ensure it's stopped | - service: iptables # ensure it's stopped | ||||
- service: ip6tables # ensure it's stopped | - service: ip6tables # ensure it's stopped | ||||
{% else %} | |||||
service_firewalld: | service_firewalld: | ||||
module.wait: | |||||
- name: service.restart | |||||
- m_name: {{ firewalld.service }} | |||||
- require: | |||||
- pkg: package_firewalld | |||||
- file: config_firewalld | |||||
- service: iptables # ensure it's stopped | |||||
- service: ip6tables # ensure it's stopped | |||||
{% else %} | |||||
service_firewalld_dead: | |||||
service.dead: | service.dead: | ||||
- name: {{ firewalld.service }} | - name: {{ firewalld.service }} | ||||
- enable: False # don't start on boot | - enable: False # don't start on boot |
- require: | - require: | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
# == Define: firewalld.services | # == Define: firewalld.services | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- file: directory_firewalld_services | - file: directory_firewalld_services | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
- context: | - context: | ||||
name: {{ s_name }} | name: {{ s_name }} | ||||
service: {{ v }} | service: {{ v }} |
- require: | - require: | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
# == Define: firewalld.zones | # == Define: firewalld.zones | ||||
# | # | ||||
- pkg: package_firewalld # make sure package is installed | - pkg: package_firewalld # make sure package is installed | ||||
- file: directory_firewalld_zones | - file: directory_firewalld_zones | ||||
- listen_in: | - listen_in: | ||||
- service: service_firewalld # restart service | |||||
- module: service_firewalld # restart service | |||||
- context: | - context: | ||||
name: {{ z_name }} | name: {{ z_name }} | ||||
zone: {{ v }} | zone: {{ v }} |