Ansible roles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
672 B

---
- name: Handle mailman web port in the firewall
iptables_raw:
name: mailman_web_port
state: "{{ (mailman_web_src_ip | length > 0) | ternary('present','absent') }}"
rules: "-A INPUT -m state --state NEW -p tcp --dport {{ mailman_web_port }} -s {{ mailman_web_src_ip | join(',') }} -j ACCEPT"
tags: firewall,mailman
- name: Handle mailman LMTP port in the firewall
iptables_raw:
name: mailman_lmtp_port
state: "{{ (mailman_lmtp_src_ip | length > 0) | ternary('present','absent') }}"
rules: "-A INPUT -m state --state NEW -p tcp --dport {{ mailman_lmtp_port }} -s {{ mailman_lmtp_src_ip | join(',') }} -j ACCEPT"
tags: firewall,mailman