mirror of https://github.com/zulip/zulip.git
puppet: Rename env-wal-e to env-wal-g.
It runs wal-g now, not wal-e; make its name respect that.
This commit is contained in:
parent
4fe0444108
commit
b114eb2f10
|
@ -45,7 +45,7 @@ if len(pg_data_paths) != 1:
|
|||
print(f"Postgres installation is not unique: {pg_data_paths}")
|
||||
sys.exit(1)
|
||||
pg_data_path = pg_data_paths[0]
|
||||
run(['env-wal-e', 'backup-push', pg_data_path])
|
||||
run(['env-wal-g', 'backup-push', pg_data_path])
|
||||
|
||||
now = datetime.now(tz=timezone.utc)
|
||||
with open('/var/lib/nagios_state/last_postgres_backup', 'w') as f:
|
||||
|
@ -53,7 +53,7 @@ with open('/var/lib/nagios_state/last_postgres_backup', 'w') as f:
|
|||
f.write("\n")
|
||||
|
||||
backups: Dict[datetime, str] = {}
|
||||
lines = run(['env-wal-e', 'backup-list']).split("\n")
|
||||
lines = run(['env-wal-g', 'backup-list']).split("\n")
|
||||
for line in lines[1:]:
|
||||
if line:
|
||||
backup_name, date_str, _, _ = line.split()
|
||||
|
@ -62,7 +62,7 @@ for line in lines[1:]:
|
|||
one_month_ago = now - timedelta(days=30)
|
||||
for date in sorted(backups.keys(), reverse=True):
|
||||
if date < one_month_ago:
|
||||
run(['env-wal-e', 'delete', '--confirm', 'before', backups[date]])
|
||||
run(['env-wal-g', 'delete', '--confirm', 'before', backups[date]])
|
||||
# Because we're going from most recent to least recent, we
|
||||
# only have to do one delete operation
|
||||
break
|
||||
|
|
|
@ -80,12 +80,12 @@ class zulip::postgres_common {
|
|||
source => 'puppet:///modules/zulip/nagios_plugins/zulip_postgres_common',
|
||||
}
|
||||
|
||||
file { '/usr/local/bin/env-wal-e':
|
||||
file { '/usr/local/bin/env-wal-g':
|
||||
ensure => file,
|
||||
owner => 'root',
|
||||
group => 'postgres',
|
||||
mode => '0750',
|
||||
source => 'puppet:///modules/zulip/postgresql/env-wal-e',
|
||||
source => 'puppet:///modules/zulip/postgresql/env-wal-g',
|
||||
require => Package[$postgresql],
|
||||
}
|
||||
|
||||
|
@ -95,7 +95,7 @@ class zulip::postgres_common {
|
|||
group => 'postgres',
|
||||
mode => '0754',
|
||||
source => 'puppet:///modules/zulip/postgresql/pg_backup_and_purge',
|
||||
require => File['/usr/local/bin/env-wal-e'],
|
||||
require => File['/usr/local/bin/env-wal-g'],
|
||||
}
|
||||
|
||||
# Use arcane puppet virtual resources to add postgres user to zulip group
|
||||
|
|
|
@ -698,7 +698,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -698,7 +698,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -698,7 +698,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -792,7 +792,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -670,7 +670,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -683,7 +683,7 @@ listen_addresses = <%= @listen_addresses %>
|
|||
wal_level = hot_standby
|
||||
max_wal_senders = 5
|
||||
archive_mode = on
|
||||
archive_command = '/usr/local/bin/env-wal-e wal-push %p'
|
||||
archive_command = '/usr/local/bin/env-wal-g wal-push %p'
|
||||
|
||||
# Standby replication settings (ignored on master)
|
||||
hot_standby = on
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
standby_mode = on
|
||||
primary_conninfo = 'host=postgres3.zulipchat.net user=replicator'
|
||||
restore_command = '/usr/local/bin/env-wal-e wal-fetch "%f" "%p"'
|
||||
restore_command = '/usr/local/bin/env-wal-g wal-fetch "%f" "%p"'
|
||||
|
|
Loading…
Reference in New Issue