add SOPS, etc.

This commit is contained in:
iofq 2024-04-07 17:54:27 -05:00
parent e1f0194350
commit 10c6af76f2
No known key found for this signature in database
GPG key ID: ECF3B2DA38BF7183
25 changed files with 435 additions and 413 deletions

32
nixos/t14/backups.nix Normal file
View file

@ -0,0 +1,32 @@
{config, ...}: {
sops = {
defaultSopsFile = ../../secrets/restic.yaml;
age.keyFile = "/home/e/.config/sops/age/keys.txt";
secrets = {
"b2-home/env" = {};
"b2-home/repo" = {};
"b2-home/password" = {};
};
};
services.restic.backups = {
b2-home = {
initialize = true;
environmentFile = config.sops.secrets."b2-home/env".path;
repositoryFile = config.sops.secrets."b2-home/repo".path;
passwordFile = config.sops.secrets."b2-home/password".path;
paths = [
"/home/e/backmeup"
"/home/e/.ssh"
"/home/e/.librewolf"
"/home/e/.runelite"
];
timerConfig = {
OnCalendar = "01:00";
};
pruneOpts = [
"--keep-last 14"
];
};
};
}