Browse Source

Add support for file external_auth special directives

Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
tags/v0.57.0
Johannes Löthberg 6 years ago
parent
commit
ec33ba5fab
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      salt/files/master.d/f_defaults.conf

+ 4
- 0
salt/files/master.d/f_defaults.conf View File

{%- for auth, users in cfg_master['external_auth']|dictsort %} {%- for auth, users in cfg_master['external_auth']|dictsort %}
{{ auth }}: {{ auth }}:
{%- for user, commands in users.items() %} {%- for user, commands in users.items() %}
{%- if user.startswith('^') %}
{{ user }}: {% raw %}'{% endraw %}{{ commands }}{% raw %}'{% endraw %}
{%- else %}
{{ user }}: {{ user }}:
{%- for command in commands %} {%- for command in commands %}
{%- if command is mapping %} {%- if command is mapping %}
- {% raw %}'{% endraw %}{{ command }}{% raw %}'{% endraw %} - {% raw %}'{% endraw %}{{ command }}{% raw %}'{% endraw %}
{%- endif %} {%- endif %}
{%- endfor -%} {%- endfor -%}
{%- endif %}
{%- endfor -%} {%- endfor -%}
{%- endfor -%} {%- endfor -%}
{%- endif %} {%- endif %}

Loading…
Cancel
Save