automatic prune of backups
This commit is contained in:
parent
31b448d615
commit
c4fd894489
2 changed files with 21 additions and 0 deletions
|
@ -22,6 +22,13 @@ in {
|
|||
repository = "rest:http://bolty:8000/";
|
||||
timerConfig = {OnCalendar = "hourly";};
|
||||
extraBackupArgs = extraArgs;
|
||||
pruneOpts = [
|
||||
"--keep-hourly 25"
|
||||
"--keep-daily 8"
|
||||
"--keep-weekly 5"
|
||||
"--keep-monthly 13"
|
||||
"--keep-yearly 2"
|
||||
];
|
||||
};
|
||||
|
||||
restic.backups.home-to-b2 = {
|
||||
|
@ -31,6 +38,13 @@ in {
|
|||
timerConfig = {OnCalendar = "hourly";};
|
||||
extraBackupArgs = extraArgs;
|
||||
environmentFile = "/etc/nixos/secrets/b2-env";
|
||||
pruneOpts = [
|
||||
"--keep-hourly 25"
|
||||
"--keep-daily 8"
|
||||
"--keep-weekly 5"
|
||||
"--keep-monthly 13"
|
||||
"--keep-yearly 2"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -37,6 +37,13 @@ in rec {
|
|||
extraBackupArgs = [
|
||||
"--exclude='cache'"
|
||||
];
|
||||
pruneOpts = [
|
||||
"--keep-hourly 25"
|
||||
"--keep-daily 8"
|
||||
"--keep-weekly 5"
|
||||
"--keep-monthly 13"
|
||||
"--keep-yearly 2"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue