paulbsd-salt/states/postgresql/users.sls

14 lines
418 B
Plaintext
Raw Normal View History

2020-07-10 00:58:55 +02:00
---
{%- from "postgresql/map.jinja" import postgresql with context %}
{%- for user in postgresql.users %}
2021-08-19 21:15:38 +02:00
postgresql-user-{{ user.name }}:
2020-07-10 00:58:55 +02:00
postgres_user.present:
- name: {{ user.name }}
{%- if user.password is defined %}
- password: {{ user.password }}
{%- endif %}
- login: {{ user.login|default(true) }}
- superuser: {{ user.superuser|default(false) }}
- db_user: postgres
{% endfor %}