summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--nixos/kusanagi.nix26
-rw-r--r--nixpkgs/kusanagi.nix10
2 files changed, 31 insertions, 5 deletions
diff --git a/nixos/kusanagi.nix b/nixos/kusanagi.nix
index 1792548..88e3b66 100644
--- a/nixos/kusanagi.nix
+++ b/nixos/kusanagi.nix
@@ -143,6 +143,32 @@ in
virtualisation.docker.enable = true;
virtualisation.virtualbox.host.enable = true;
+ # ---- remote backup (restic to infracoll)
+
+ services.restic.backups."infracoll" = {
+ repository = "s3:http://garage.isomorphis.me:3900/restic-lx";
+ environmentFile = "/persist/etc/secrets/restic/infracoll/credentials";
+ passwordFile = "/persist/etc/secrets/restic/infracoll/password";
+ paths = [
+ "/persist"
+ "/Z/lx"
+ ];
+ exclude = [
+ "/persist/var/log"
+ "/Z/lx/oneplus5/Camera" # for now
+ ];
+ timerConfig = {
+ OnCalendar = "21:30";
+ Persistent = true;
+ };
+ pruneOpts = [
+ "--keep-daily 7"
+ "--keep-weekly 5"
+ "--keep-monthly 12"
+ "--keep-yearly 75"
+ ];
+ };
+
# ----
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
diff --git a/nixpkgs/kusanagi.nix b/nixpkgs/kusanagi.nix
index 5508965..19b367d 100644
--- a/nixpkgs/kusanagi.nix
+++ b/nixpkgs/kusanagi.nix
@@ -23,16 +23,16 @@ in {
mklink /Z/lx/app/openssh ~/.ssh
mklink /Z/lx/app/pass ~/.password-store
mklink /Z/lx/app/thunderbird ~/.thunderbird
- mklink /Z/lx/app/cargo ~/.cargo
+ mklink /Z/lx.nobackup/app/cargo ~/.cargo
mklink /Z/lx/app/rclone/rclone.conf ~/.config/rclone/rclone.conf
- mklink /Z/lx/app/arduino/Arduino ~/Arduino
- mklink /Z/lx/app/arduino/.arduino15 ~/.arduino15
+ mklink /Z/lx.nobackup/app/arduino/Arduino ~/Arduino
+ mklink /Z/lx.nobackup/app/arduino/.arduino15 ~/.arduino15
mklink /Z/lx/app/tagaini "$HOME/.local/share/Tagaini Jisho"
mklink /Z/lx/app/anki "$HOME/.local/share/Anki2"
- mklink /Z/lx/app/steam/.steam ~/.steam
- mklink /Z/lx/app/steam/Steam ~/.local/share/Steam
+ mklink /Z/lx.nobackup/app/steam/.steam ~/.steam
+ mklink /Z/lx.nobackup/app/steam/Steam ~/.local/share/Steam
mklink /Z/lx/app/element ~/.config/Element
mklink /Z/lx/app/dino ~/.local/share/dino