borg-backup: setup paths in respective services

This commit is contained in:
Antoine Martin 2021-01-31 13:00:04 +01:00
parent 8ed0f14f74
commit 41769615f0
4 changed files with 19 additions and 5 deletions

View file

@ -15,5 +15,14 @@ in {
# Borg backup starts at midnight so create DB dump just before
startAt = "*-*-* 23:30:00";
};
my.services.borg-backup = mkIf cfg.enable {
paths = [ "/var/backup/postgresql" ];
# no need to store previously backed up files, as borg does the snapshoting
# for us
exclude = [ "/var/backup/postgresql/*.prev.sql.gz" ];
};
};
}