Adding variable for managing firewall ports

This commit is contained in:
Tyler Hale 2021-09-25 08:41:14 -06:00
parent c5283b1487
commit d038403979
Signed by: Tyler
GPG key ID: 3F9270F8F70AC13D
3 changed files with 24 additions and 26 deletions

View file

@ -110,19 +110,7 @@
permanent: yes
immediate: yes
state: enabled
with_items:
- {port: "22", protocol: "tcp"}
- {port: "80", protocol: "tcp"}
- {port: "443", protocol: "tcp"}
notify: reload firewalld
become: yes
- name: Enable firewall ports for haproxy stats
firewalld:
port: "9999/tcp"
permanent: yes
immediate: yes
state: enabled
loop: "{{ haproxy_listen_ports }}"
notify: reload firewalld
become: yes