diff options
Diffstat (limited to 'modules/private')
-rw-r--r-- | modules/private/databases/postgresql_replication.nix | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/private/databases/postgresql_replication.nix b/modules/private/databases/postgresql_replication.nix index 6ac2455..b103b8c 100644 --- a/modules/private/databases/postgresql_replication.nix +++ b/modules/private/databases/postgresql_replication.nix | |||
@@ -119,7 +119,7 @@ in | |||
119 | ${hcfg.package}/bin/pg_dumpall -h ${dataDir} -f ${backupDir}/$(${pkgs.coreutils}/bin/date -Iminutes).sql | 119 | ${hcfg.package}/bin/pg_dumpall -h ${dataDir} -f ${backupDir}/$(${pkgs.coreutils}/bin/date -Iminutes).sql |
120 | ''; | 120 | ''; |
121 | u = pkgs.callPackage ./utils.nix {}; | 121 | u = pkgs.callPackage ./utils.nix {}; |
122 | cleanup_script = pkgs.writeScript "cleanup_postgresql_${name}" (u.keepLastNDumps "sql" backupDir 12); | 122 | cleanup_script = pkgs.writeScript "cleanup_postgresql_${name}" (u.keepLastNDumps "sql" backupDir 6); |
123 | in [ | 123 | in [ |
124 | "0 22,4,10,16 * * * postgres ${backup_script}" | 124 | "0 22,4,10,16 * * * postgres ${backup_script}" |
125 | "0 3 * * * postgres ${cleanup_script}" | 125 | "0 3 * * * postgres ${cleanup_script}" |