diff options
Diffstat (limited to 'hosts/common/server')
-rw-r--r-- | hosts/common/server/prometheus.nix | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/hosts/common/server/prometheus.nix b/hosts/common/server/prometheus.nix index d939a5a..d097cff 100644 --- a/hosts/common/server/prometheus.nix +++ b/hosts/common/server/prometheus.nix @@ -52,4 +52,18 @@ in { } ]; }; + + age.secrets.restic-repo-systems.file = + ../../../secrets/restic/repo-systems.age; + + services.restic.backups = { + prometheus = { + paths = [ "/var/lib/prometheus2" ]; + repository = "/data/slow/backups/systems"; + passwordFile = config.age.secrets.restic-repo-systems.path; + initialize = true; + extraBackupArgs = [ "--tag prometheus" ]; + pruneOpts = [ "--keep-daily 7" "--keep-weekly 4" ]; + }; + }; } |