29 lines
655 B
Nix
29 lines
655 B
Nix
|
{config, ...}: let
|
||
|
secrets = config.services.secrets.secrets;
|
||
|
in {
|
||
|
services.restic.backups.lappy-t495 = {
|
||
|
user = "root";
|
||
|
createWrapper = true;
|
||
|
|
||
|
paths = [
|
||
|
"/etc/NetworkManager/system-connections"
|
||
|
"/home/chaos/Projects"
|
||
|
];
|
||
|
extraBackupArgs = [
|
||
|
"--exclude-caches"
|
||
|
"--exclude=node_modules"
|
||
|
"--exclude=/home/chaos/Projects/*/target"
|
||
|
];
|
||
|
|
||
|
repositoryFile = "${secrets.restic_backups_repository_file.path}";
|
||
|
passwordFile = "${secrets.restic_backups_password.path}";
|
||
|
|
||
|
pruneOpts = ["--keep-within=14d"];
|
||
|
|
||
|
timerConfig = {
|
||
|
OnStartupSec = "5m";
|
||
|
OnUnitActiveSec = "30m";
|
||
|
};
|
||
|
};
|
||
|
}
|