Files
ansible/roles/ntp/templates/etc_firewall_rules-v4.d_21_ntp.sh.j2
2025-10-10 11:07:34 +00:00

7 lines
253 B
Django/Jinja

# {{ ansible_managed }}
{% for ip in ntp_servers | default([]) %}
iptables -A INPUT -s {{ ip }} -p udp --dport 123 -m comment --comment "ntp" -j ACCEPT
iptables -A OUTPUT -d {{ ip }} -p udp --dport 123 -m comment --comment "ntp" -j ACCEPT
{% endfor %}