summary refs log tree commit diff
path: root/mixins
diff options
context:
space:
mode:
authortzlil <tzlils@protonmail.com>2023-05-18 19:40:01 +0300
committertzlil <tzlils@protonmail.com>2023-05-18 19:40:01 +0300
commit959dfaaeb7ae01a77f9e2c3c17bac1b7e23d8ea1 (patch)
treea169856c7c33530aa1b3b7482fe6c8bc4685f456 /mixins
parent57cbc3ac65272242bfee162b916d9675935e9c2e (diff)
add keepassxc to laptop, setup syncthing
Diffstat (limited to 'mixins')
-rw-r--r--mixins/syncthing.nix38
1 files changed, 38 insertions, 0 deletions
diff --git a/mixins/syncthing.nix b/mixins/syncthing.nix
new file mode 100644
index 0000000..3e219ae
--- /dev/null
+++ b/mixins/syncthing.nix
@@ -0,0 +1,38 @@
+{
+  pkgs,
+  config,
+  ...
+}: {
+  config = {
+    services.syncthing = {
+      enable = true;
+      user = "tzlil";
+      dataDir = "/home/tzlil/sync";
+      configDir = "/home/tzlil/.config/syncthing";
+      overrideDevices = true;
+      overrideFolders = true;
+      devices = {
+        "phone" = {id = "UHWVTEZ-BERNFCH-3ZXQHNE-ZRBHLU6-MBAVEHB-TKLQJM7-ZGHLJ4R-6E4SAA7";};
+      };
+      folders = {
+        "passwords" = {
+          path = "/home/tzlil/sync/passwords";
+          devices = ["phone"];
+        };
+      };
+    };
+
+    environment.persistence."/nix/persist".directories = [
+      {
+        directory = "/home/tzlil/sync";
+        user = "tzlil";
+        group = "users";
+      }
+      {
+        directory = "/home/tzlil/.config/syncthing";
+        user = "tzlil";
+        group = "users";
+      }
+    ];
+  };
+}