]>
Commit | Line | Data |
---|---|---|
436cae5e | 1 | define profile::postgresql::master ( |
f568173a IB |
2 | $letsencrypt_host = undef, |
3 | $backup_hosts = [], | |
4 | ) { | |
d2f031ec IB |
5 | profile::postgresql::ssl { "/var/lib/postgres/data": |
6 | cert => "/etc/letsencrypt/live/$letsencrypt_host/cert.pem", | |
7 | key => "/etc/letsencrypt/live/$letsencrypt_host/privkey.pem", | |
8 | require => Letsencrypt::Certonly[$letsencrypt_host], | |
9 | handle_config_entry => true, | |
c53ac3f8 | 10 | } |
f568173a IB |
11 | |
12 | $backup_hosts.each |$backup_host| { | |
c53ac3f8 | 13 | profile::postgresql::replication { $backup_host: |
d2f031ec | 14 | handle_config => true, |
c53ac3f8 IB |
15 | handle_role => true, |
16 | handle_slot => true, | |
17 | add_self_role => true, | |
f568173a | 18 | } |
5feedbb4 | 19 | } |
f568173a | 20 | } |