about summary refs log tree commit diff
path: root/hosts
diff options
context:
space:
mode:
Diffstat (limited to 'hosts')
-rw-r--r--hosts/aptos/services.nix24
1 files changed, 16 insertions, 8 deletions
diff --git a/hosts/aptos/services.nix b/hosts/aptos/services.nix
index 1168dc2..3bb56b2 100644
--- a/hosts/aptos/services.nix
+++ b/hosts/aptos/services.nix
@@ -1,5 +1,7 @@
 { config, ... }:
-let secrets = config.age.secrets;
+let
+  secrets = config.age.secrets;
+  ssh-key-path = secrets."restic/ssh-key".path;
 in
 {
   my.services = {
@@ -22,20 +24,26 @@ in
 
     backup = {
       enable = true;
-      user = "fcuny";
-      repository = "sftp:192.168.6.40:/";
+      repository = "sftp:192.168.6.40:/aptos";
       exclude = [
-        "/home/fcuny/.cache"
-        "/home/fcuny/downloads"
-        "/home/fcuny/workspace/linux.git"
+        # paths that I don't want to backup
         "/home/fcuny/workspace/tmp"
+
+        # various development related files
+        "**/target"
+        "**/.direnv"
+        "**/result"
       ];
       timerConfig = { OnCalendar = "06:30"; };
       passwordFile = secrets."restic/repo-users".path;
       extraOptions = [
-        "sftp.command='ssh fcunybackup@192.168.6.40 -i ${secrets.restic/ssh-key.path} -s sftp'"
+        "sftp.command='ssh backup@192.168.6.40 -i ${ssh-key-path} -s sftp'"
+      ];
+      paths = [
+        "/home/fcuny/workspace"
+        "/home/fcuny/media"
+        "/home/fcuny/documents"
       ];
-      paths = [ "/home/fcuny" ];
     };
   };
 }