From 109c6be0b1bcd3ac5edac763d0ae96d9d55ab384 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Tue, 25 Feb 2025 08:42:02 +0100 Subject: [PATCH] feat(syncthing): configure devices and folders Added configuration for Syncthing devices and shared folders, enabling synchronization between specific devices. Adjusted the structure for better clarity and maintainability. --- systems/x86_64-linux/sgx/fileserver.nix | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/systems/x86_64-linux/sgx/fileserver.nix b/systems/x86_64-linux/sgx/fileserver.nix index 9a60c44..e2ff569 100644 --- a/systems/x86_64-linux/sgx/fileserver.nix +++ b/systems/x86_64-linux/sgx/fileserver.nix @@ -70,14 +70,26 @@ }; }; - services = { - syncthing = { + services.syncthing = { enable = true; user = "harald"; dataDir = "/mnt/raid/Qmultimedia/syncthing"; # Default folder for new synced folders configDir = "/mnt/raid/Qmultimedia/syncthing/.config/syncthing"; # Folder for Syncthing's settings and keys guiAddress = "127.0.0.1:8384"; settings.gui.insecureSkipHostcheck = true; - }; + devices = { + "sgx" = { id = "2AAVSVQ-PK66I2B-2B4KWAU-TF674DG-IXNEKLF-CIWK7HG-7MUC7OW-DQQNAQM"; }; + "S25" = { id = "7Q7XQXG-VF7QM6Y-HJST4V2-RWOPB3M-GHXQDLL-SRRN3IL-3PHKNOZ-D2IFIQV"; }; + }; + folders = { + "Documents" = { + path = "~/logseq"; + devices = [ "sgx" "S25" ]; + }; + "Example" = { + path = "/mnt/raid/Qmultimedia/S25-Kamera"; + devices = [ "sgx" "S25" ]; + }; + }; }; }