|
|
|
|
|
|
|
|
{%- for interface_name, interface_details in ufw.get('interfaces', {}).items() %} |
|
|
{%- for interface_name, interface_details in ufw.get('interfaces', {}).items() %} |
|
|
{%- set comment = interface_details.get('comment', None) %} |
|
|
{%- set comment = interface_details.get('comment', None) %} |
|
|
|
|
|
|
|
|
ufw-interface-{{interface_name}}: |
|
|
|
|
|
|
|
|
ufw-interface-{{ interface_name }}: |
|
|
ufw.allowed: |
|
|
ufw.allowed: |
|
|
- interface: {{interface_name}} |
|
|
|
|
|
|
|
|
- interface: {{ interface_name }} |
|
|
{%- if comment is not none %} |
|
|
{%- if comment is not none %} |
|
|
- comment: '"{{comment}}"' |
|
|
|
|
|
|
|
|
- comment: '"{{ comment }}"' |
|
|
{%- endif %} |
|
|
{%- endif %} |
|
|
- listen_in: |
|
|
- listen_in: |
|
|
- cmd: reload-ufw |
|
|
- cmd: reload-ufw |