mirror of
https://github.com/kittywitch/nixfiles.git
synced 2026-02-09 04:19:19 -08:00
feat: add backups, misc over-time changes
This commit is contained in:
parent
a7f901970d
commit
2b5630d487
6 changed files with 93 additions and 3 deletions
30
nixos/profiles/graphical/restic.nix
Normal file
30
nixos/profiles/graphical/restic.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ config, ... }: {
|
||||
sops.secrets.restic-password-file = {
|
||||
sopsFile = ./restic.yaml;
|
||||
};
|
||||
services.restic.backups = {
|
||||
${config.networking.hostName} = {
|
||||
paths = [
|
||||
"/home/kat/Documents"
|
||||
"/home/kat/Pictures"
|
||||
];
|
||||
exclude = [
|
||||
];
|
||||
extraOptions = [
|
||||
"sftp.command='ssh u401227@u401227.your-storagebox.de -i /home/kat/.ssh/id_ed25519 -s sftp'"
|
||||
];
|
||||
pruneOpts = [
|
||||
"--keep-daily 7"
|
||||
"--keep-weekly 2"
|
||||
"--keep-monthly 6"
|
||||
];
|
||||
initialize = true;
|
||||
passwordFile = config.sops.secrets.restic-password-file.path;
|
||||
repository = "sftp:u401227@u401227.your-storagebox.de:/restic/koishi";
|
||||
timerConfig = {
|
||||
OnCalendar = "00:05";
|
||||
RandomizedDelaySec = "5h";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue