diff --git a/tasks/nginx.yml b/tasks/nginx.yml index a4af4f0..7778cad 100644 --- a/tasks/nginx.yml +++ b/tasks/nginx.yml @@ -23,7 +23,7 @@ iptables_raw: name: allow_unifi_nginx_proxy state: present - rules: '-A OUTPUT -p tcp -d {{ unifi_server_ip }} -m --dport {{ unifi_server_port }} -j ACCEPT' + rules: '-A OUTPUT -m state --state NEW -p tcp -d {{ unifi_server_ip }} --dport {{ unifi_server_port }} -j ACCEPT' when: unifi_nginx_iptables_enabled delegate_to: "{{ unifi_nginx_server }}" become: True