ansible-role-icinga2/templates/users.conf.j2
2021-01-03 16:10:04 +01:00

22 lines
593 B
Django/Jinja

# {{ ansible_managed }}
{% for name, group in icinga2_user_groups.items() %}
object UserGroup "{{ name }}" {
display_name = "{{ group.display_name|default(name) }}"
}
{% endfor %}
{% for name, user in icinga2_users.items() %}
object User "{{ name }}" {
display_name = "{{ user.display_name|default(name) }}"
groups = [ "{{ user.groups|join(', "') }}" ]
email = "{{ user.email }}"
}
{% endfor %}
{% for name, user in icinga2_api_users.items() %}
object ApiUser "{{ name }}" {
password = "{{ user.password }}"
permissions = [ "{{ user.permissions|join(', "') }}" ]
}
{% endfor %}