From 08d5d0806104e4c40b61243d57bcae86bcf6b3c7 Mon Sep 17 00:00:00 2001 From: Crony Akatsuki Date: Sat, 23 Aug 2025 12:35:04 +0200 Subject: [PATCH] feat(servers): local backup only keeps 2 recent snapshots. --- modules/servers/general/restic.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/servers/general/restic.nix b/modules/servers/general/restic.nix index 17b1544..4681205 100644 --- a/modules/servers/general/restic.nix +++ b/modules/servers/general/restic.nix @@ -9,6 +9,9 @@ "--keep-weekly 5" "--keep-monthly 12" ]; + pruneOptsLocal = [ + "--keep-last 2" + ]; checkOpts = [ "--read-data-subset=10%" "--with-cache" @@ -21,7 +24,7 @@ in { passwordFile = config.age.secrets.restic-server-local-pass.path; repository = "/var/lib/backup"; paths = opts.paths; - pruneOpts = opts.pruneOpts; + pruneOpts = opts.pruneOptsLocal; checkOpts = opts.checkOpts; }; server = {