Ansible-Roles/roles/postgresql/templates/pg_hba.conf.j2
2026-05-08 22:25:29 +03:00

12 lines
802 B
Django/Jinja

{{ ansible_managed | comment }}
# PostgreSQL Client Authentication Configuration File
# ===================================================
#
# See: https://www.postgresql.org/docs/current/static/auth-pg-hba-conf.html
# TYPE DATABASE USER ADDRESS METHOD
local all postgres peer
{% for client in postgresql_hba_entries %}
{{ client.type.ljust(10) }} {{ client.database.ljust(15) }} {{ client.user.ljust(15) }} {%if client.address is defined %} {{ client.address.ljust(20)|default('') }} {% endif %} {% if client.ip_address is defined %} {{ client.ip_address.ljust(20)|default('') }} {% endif %} {{ client.ip_mask|default('') }} {{ client.auth_method.ljust(10) }} {{ client.auth_options|default("") }}
{% endfor %}