25 lines
914 B
Plaintext
25 lines
914 B
Plaintext
|
{%- from "clickhouse/map.jinja" import clickhouse with context -%}
|
||
|
<clickhouse>
|
||
|
<users>
|
||
|
<{{ name }}>
|
||
|
<networks>
|
||
|
{%- for network in params.networks|default(["127.0.0.1/8"]) %}
|
||
|
<ip>{{ network }}</ip>
|
||
|
{%- endfor %}
|
||
|
</networks>
|
||
|
<profile>{{ params.profile|default("default") }}</profile>
|
||
|
<quota>{{ params.quota|default("default") }}</quota>
|
||
|
<default_database>{{ params.default_database|default("default") }}</default_database>
|
||
|
<access_management>{{ params.access_management|default(0)}}</access_management>
|
||
|
{%- if params.databases|default([])|length > 0 %}
|
||
|
<allow_databases>
|
||
|
{%- for database in params.databases|default([]) %}
|
||
|
<database>{{ database }}</database>
|
||
|
{%- endfor %}
|
||
|
</allow_databases>
|
||
|
{%- endif %}
|
||
|
<password>{{ params.password|default("") }}</password>
|
||
|
</{{ name }}>
|
||
|
</users>
|
||
|
</clickhouse>
|