diff options
| author | Jakub Stachurski <j.stachurski@student.utwente.nl> | 2025-11-19 21:02:52 +0100 |
|---|---|---|
| committer | Jakub Stachurski <j.stachurski@student.utwente.nl> | 2025-11-19 21:02:52 +0100 |
| commit | 892de67a9f64d0b0cdb023d830a019d8feec0a57 (patch) | |
| tree | 0c5fd0c60ef93bb5cdc5f83c8cade0c5dddb4899 /hosts/apocalypse/backup.nix | |
| parent | f5b37610b3835ea26757ef36d554ec598d53100c (diff) | |
Nix fmt
Diffstat (limited to 'hosts/apocalypse/backup.nix')
| -rw-r--r-- | hosts/apocalypse/backup.nix | 46 |
1 files changed, 26 insertions, 20 deletions
diff --git a/hosts/apocalypse/backup.nix b/hosts/apocalypse/backup.nix index 3529024..1942d66 100644 --- a/hosts/apocalypse/backup.nix +++ b/hosts/apocalypse/backup.nix @@ -1,31 +1,37 @@ -{ config, lib, pkgs, modulesPath, ...}: +{ + config, + lib, + pkgs, + modulesPath, + ... +}: { environment.systemPackages = with pkgs; [ btrbk lz4 ]; - + services.btrbk = { - extraPackages = with pkgs; [ lz4 ]; - instances."remote_vault" = { - onCalendar = "weekly"; - settings = { - snapshot_preserve_min = "1w"; - snapshot_preserve = "2w"; - target_preserve_min = "1w"; - target_preserve = "4w"; - ssh_identity = "/etc/vault_key"; # NOTE: must be readable by user/group btrbk - ssh_user = "vaultmanager"; - stream_compress = "lz4"; - volume."/btrfs_root" = { - target = "ssh://10.127.9.1/vault/backups/apocalypse"; - subvolume = { - "@root" = { - snapshot_create = "ondemand"; - }; + extraPackages = with pkgs; [ lz4 ]; + instances."remote_vault" = { + onCalendar = "weekly"; + settings = { + snapshot_preserve_min = "1w"; + snapshot_preserve = "2w"; + target_preserve_min = "1w"; + target_preserve = "4w"; + ssh_identity = "/etc/vault_key"; # NOTE: must be readable by user/group btrbk + ssh_user = "vaultmanager"; + stream_compress = "lz4"; + volume."/btrfs_root" = { + target = "ssh://10.127.9.1/vault/backups/apocalypse"; + subvolume = { + "@root" = { + snapshot_create = "ondemand"; + }; + }; }; }; }; }; -}; } |
