fix(restic): cleanup stale locks before running backups

This commit is contained in:
Felix Schröter 2023-07-21 16:14:43 +02:00
parent c31a727501
commit 5928e539fb
Signed by: felschr
GPG key ID: 671E39E6744C807D
2 changed files with 12 additions and 7 deletions

View file

@ -41,5 +41,9 @@ in {
];
timerConfig.OnCalendar = "0/6:00:00";
extraPruneOpts = [ "--keep-last 4" ];
backupPrepareCommand = ''
# remove stale locks
${pkgs.restic}/bin/restic unlock || true
'';
};
}