about summary refs log tree commit diff
path: root/profiles
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2023-05-10 20:09:14 -0700
committerFranck Cuny <franck@fcuny.net>2023-05-10 20:09:14 -0700
commit439e940037e2a0a37d7d59ac64e65518867aac15 (patch)
tree32965be1cde8e59e1f4940e651ff23af6194ef1e /profiles
parentprofiles/seedbox: move transmission to it (diff)
downloadworld-439e940037e2a0a37d7d59ac64e65518867aac15.tar.gz
profiles/syncthing: move the old module
Diffstat (limited to '')
-rw-r--r--profiles/syncthing.nix44
1 files changed, 44 insertions, 0 deletions
diff --git a/profiles/syncthing.nix b/profiles/syncthing.nix
new file mode 100644
index 0000000..6dcb503
--- /dev/null
+++ b/profiles/syncthing.nix
@@ -0,0 +1,44 @@
+{ config, pkgs, lib, ... }:
+let
+  secrets = config.age.secrets;
+in
+{
+  services.syncthing = {
+    enable = true;
+    openDefaultPorts = true;
+    user = "fcuny";
+    group = "users";
+    dataDir = "/home/fcuny/.local/state/syncthing";
+    cert = secrets."syncthing/cert".path;
+    key = secrets."syncthing/key".path;
+
+    folders.Documents = {
+      path = "/home/fcuny/documents";
+      devices = [ "aptos" "tahoe" ];
+    };
+
+    folders.PixelCamera = {
+      path = "/home/fcuny/media/pixel/camera";
+      id = "pixel_5_vwsr-photos";
+      devices = lib.attrNames config.services.syncthing.devices;
+    };
+
+    devices = {
+      aptos = {
+        id =
+          "JAN5UMH-2FAQQ7S-KLQ2YXM-C7KKK7U-HVHUK7I-CWOZQRM-VLQSO63-ZTP4WAN";
+        introducer = false;
+      };
+      tahoe = {
+        id =
+          "4Y36C3Y-LUTO6LD-JXNV73B-FLXSTNP-5Q3CSPY-HESHTPH-EDYA54K-WEICJAJ";
+        introducer = true;
+      };
+      pixel = {
+        id =
+          "J3JQFCJ-MY5RCF7-4NXMVU5-2JECKWO-UHFUS5T-KO64EMB-RNUV4F2-ZQ7Z6A6";
+        introducer = false;
+      };
+    };
+  };
+}