Skip to content
Snippets Groups Projects
Commit 7e3ab27f authored by Gabriel Mazetto's avatar Gabriel Mazetto
Browse files

Patroni configuration saves replication password in supported format

We are not relying on `sql_replication_password` as we need it in cleartext here.
parent 86df04c0
No related branches found
No related tags found
2 merge requests!20Configuration for Mercurial module policy,!18Draft: GitLab 13.5
......@@ -15,6 +15,8 @@
default['patroni']['master_start_timeout'] = 300
default['patroni']['use_pg_rewind'] = false
default['patroni']['use_slots'] = true
default['patroni']['replication_user'] = node['postgresql']['sql_replication_user']
default['patroni']['replication_password'] = nil
default['patroni']['replication_slots'] = {}
# Standby cluster replication settings
......
......@@ -19,9 +19,9 @@
superuser:
username: <%= account_helper.postgresql_user %>
replication:
username: <%= @postgresql_defaults['sql_replication_user'] %>
<% if @postgresql_defaults['sql_replication_password'] %>
password: <%= "md5#{@postgresql_defaults['sql_replication_password']}" %>
username: <%= @replication_user %>
<% if @replication_password %>
password: <%= "#{@replication_password}" %>
<% end %>
bootstrap:
dcs: <%= patroni_helper.dynamic_settings.to_json %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment