paulbsd-salt/states/sudo/templates/sudoers.j2
2023-03-10 00:08:10 +01:00

17 lines
536 B
Django/Jinja

## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }}
{%- from "sudo/map.jinja" import sudo with context %}
{%- if sudo.config.defaults is defined -%}
{%- for default in sudo.config.defaults %}
Defaults {{ default }}
{%- endfor %}
{%- endif %}
{%- if sudo.config.acls is defined -%}
{%- for key, acl in sudo.config.acls.items() %}
{% if acl.group %}%{% endif %}{{ key }} {{ acl.host|default('ALL') }}=({{ acl.who|default('ALL') }}) {{ acl.command|default('ALL') }}
{%- endfor %}
{%- endif %}
#includedir /etc/sudoers.d