summary refs log tree commit diff
path: root/nixos/modules/services/backup/postgresql-backup.nix
diff options
context:
space:
mode:
authorMartin Weinelt <hexa@darmstadt.ccc.de>2021-05-14 18:14:03 +0200
committerMartin Weinelt <hexa@darmstadt.ccc.de>2021-05-14 20:41:08 +0200
commit21746a7c80619f72c8197486940fc60183602656 (patch)
treeefb3bfa95b4a1ec6436bf2c98db23e96b0896407 /nixos/modules/services/backup/postgresql-backup.nix
parent2f06be9f99f56275951d7b3a3f642608e2f90fe7 (diff)
downloadnixpkgs-21746a7c80619f72c8197486940fc60183602656.tar
nixpkgs-21746a7c80619f72c8197486940fc60183602656.tar.gz
nixpkgs-21746a7c80619f72c8197486940fc60183602656.tar.bz2
nixpkgs-21746a7c80619f72c8197486940fc60183602656.tar.lz
nixpkgs-21746a7c80619f72c8197486940fc60183602656.tar.xz
nixpkgs-21746a7c80619f72c8197486940fc60183602656.tar.zst
nixpkgs-21746a7c80619f72c8197486940fc60183602656.zip
nixos/postgresqlBackup: allow defining multiple times to start at
Or … none! Because forcing a string always results in an OnCalender=
setting, but an empty string leads to an empty value.

>  postgresqlBackup-hass.timer: Timer unit lacks value setting. Refusing.

or

> postgresqlBackup-miniflux.timer: Cannot add dependency job, ignoring: Unit postgresqlBackup-miniflux.timer has a bad unit file setting.

I require the postgresqlBackup in my borgbackup unit, so I don't
strictly need the timer and could previously set it to an empty list.
Diffstat (limited to 'nixos/modules/services/backup/postgresql-backup.nix')
-rw-r--r--nixos/modules/services/backup/postgresql-backup.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/services/backup/postgresql-backup.nix b/nixos/modules/services/backup/postgresql-backup.nix
index f4bd3aa447e..9da2d522a68 100644
--- a/nixos/modules/services/backup/postgresql-backup.nix
+++ b/nixos/modules/services/backup/postgresql-backup.nix
@@ -48,7 +48,7 @@ in {
 
       startAt = mkOption {
         default = "*-*-* 01:15:00";
-        type = types.str;
+        type = with types; either (listOf str) str;
         description = ''
           This option defines (see <literal>systemd.time</literal> for format) when the
           databases should be dumped.