summaryrefslogtreecommitdiff
path: root/config/storage.nix
diff options
context:
space:
mode:
authorquentin@aristote.fr <quentin@aristote.fr>2025-10-24 22:02:25 +0200
committerquentin@aristote.fr <quentin@aristote.fr>2025-10-24 22:24:48 +0200
commitef4370dab21c97da96da5f0acef7a736e55fcf7c (patch)
treea3a29c3b7716c48e046e9875070b86a1b857d17b /config/storage.nix
parent434a068393b266bedfa2d98d1e4c15d2cd5c52cd (diff)
storage: enable borg
Diffstat (limited to 'config/storage.nix')
-rw-r--r--config/storage.nix20
1 files changed, 17 insertions, 3 deletions
diff --git a/config/storage.nix b/config/storage.nix
index ecb2dc1..2ebb78a 100644
--- a/config/storage.nix
+++ b/config/storage.nix
@@ -1,5 +1,6 @@
-{...}: {
- boot.supportedFilesystems = ["nfs"];
+{ ... }:
+{
+ boot.supportedFilesystems = [ "nfs" ];
fileSystems."/backups" = {
device = "ds411.aristote.mesh:/volume2/hephaistos";
fsType = "nfs";
@@ -12,5 +13,18 @@
];
};
- services.restic.backups = {};
+ services.borgbackup.jobs.srv = {
+ paths = "/srv";
+ exclude = [ ];
+ repo = "/backups/srv";
+ doInit = false;
+ encryption = {
+ mode = "repokey";
+ passCommand = "cat /etc/borg/passphrase";
+ };
+ compression = "auto,lzma";
+ startAt = "daily";
+ prune.keep.daily = 7;
+ };
+ systemd.services.borgbackup-job-srv.personal.monitor = true;
}