Browse Source

fix(interfaces.sls): fix `salt-lint` errors

```bash
Examining ufw/config/interfaces.sls of type state
[206] Jinja variables should have spaces before and after: {{ var_name }}
ufw/config/interfaces.sls:20
ufw-interface-{{interface_name}}:

[206] Jinja variables should have spaces before and after: {{ var_name }}
ufw/config/interfaces.sls:22
    - interface: {{interface_name}}

[206] Jinja variables should have spaces before and after: {{ var_name }}
ufw/config/interfaces.sls:24
    - comment: '"{{comment}}"'
```
tags/v0.5.2
Imran Iqbal 5 years ago
parent
commit
0c9440e4cd
No account linked to committer's email address
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      ufw/config/interfaces.sls

+ 3
- 3
ufw/config/interfaces.sls View File

{%- 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

Loading…
Cancel
Save