Created
August 14, 2018 13:46
-
-
Save imcitius/185ef685042ba131f91eb69d61d029e6 to your computer and use it in GitHub Desktop.
patroni-conifg
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'pgsql-main-0' | |
scope: &scope 'pgsql-main' | |
consul: | |
host: '172.29.10.58' | |
restapi: | |
listen: 172.29.10.58:8008 | |
connect_address: 172.29.10.58:8008 | |
auth: 'username:123123123' | |
bootstrap: | |
dcs: | |
ttl: &ttl 30 | |
loop_wait: &loop_wait 10 | |
maximum_lag_on_failover: 1048576 # 1 megabyte in bytes | |
synchronous_mode: true | |
postgresql: | |
use_pg_rewind: true | |
use_slots: true | |
parameters: | |
max_connections: 200 | |
synchronous_commit: "on" | |
synchronous_standby_names: "" | |
archive_mode: "off" | |
wal_level: "replica" | |
archive_command: /bin/true | |
max_wal_senders: 10 | |
wal_keep_segments: 8 | |
archive_timeout: 1800s | |
max_replication_slots: 5 | |
hot_standby: "on" | |
wal_log_hints: "on" | |
pg_hba: # Add following lines to pg_hba.conf after running 'initdb' | |
- host replication all 0.0.0.0/0 md5 | |
- host replication all 127.0.0.1/8 md5 | |
- host all all 0.0.0.0/0 md5 | |
users: | |
replication: | |
username: replicator | |
password: '123123123' | |
superuser: | |
username: superuser | |
password: '123123123' | |
postgresql: | |
superuser: | |
username: superuser | |
password: '123123123' | |
replication: | |
username: replicator | |
password: '123123123' | |
connect_address: 172.29.10.58:5432 | |
data_dir: /var/lib/pgsql/10/data | |
listen: 0.0.0.0:5432 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment