From a380a1bea21145c52c754f8f151ce0abaa2f5c02 Mon Sep 17 00:00:00 2001 From: Richie Cahill Date: Sun, 9 Jun 2024 09:47:30 -0400 Subject: [PATCH] set up syncthing --- systems/bob/configuration.nix | 54 ++++++++++++++++++++- systems/jeeves/configuration.nix | 9 +++- systems/rhapsody-in-green/configuration.nix | 9 +++- users/richie/global/syncthing_base.nix | 1 + 4 files changed, 69 insertions(+), 4 deletions(-) diff --git a/systems/bob/configuration.nix b/systems/bob/configuration.nix index 3fedd1a..2aaac96 100644 --- a/systems/bob/configuration.nix +++ b/systems/bob/configuration.nix @@ -27,8 +27,6 @@ sound.enable = true; services = { - openssh.settings.PermitRootLogin = "yes"; - autopull.enable = false; displayManager.sddm.enable = true; @@ -50,6 +48,58 @@ alsa.support32Bit = true; pulse.enable = true; }; + + syncthing.settings.folders = { + "notes" = { + id = "l62ul-lpweo"; # cspell:disable-line + path = "/home/richie/notes"; + devices = [ + "phone" + "jeeves" + "rhapsody-in-green" + ]; + fsWatcherEnabled = true; + }; + "books" = { + id = "6uppx-vadmy"; # cspell:disable-line + path = "/home/richie/books"; + devices = [ + "phone" + "jeeves" + "rhapsody-in-green" + ]; + fsWatcherEnabled = true; + }; + "important" = { + id = "4ckma-gtshs"; # cspell:disable-line + path = "/home/richie/important"; + devices = [ + "phone" + "jeeves" + "rhapsody-in-green" + ]; + fsWatcherEnabled = true; + }; + "music" = { + id = "vprc5-3azqc"; # cspell:disable-line + path = "/home/richie/music"; + devices = [ + "phone" + "jeeves" + "rhapsody-in-green" + ]; + "projects" = { + id = "vyma6-lqqrz"; # cspell:disable-line + path = "/home/richie/projects"; + devices = [ + "jeeves" + "rhapsody-in-green" + ]; + fsWatcherEnabled = true; + }; + fsWatcherEnabled = true; + }; + }; }; system.autoUpgrade.enable = false; diff --git a/systems/jeeves/configuration.nix b/systems/jeeves/configuration.nix index 9460dfd..a7a9842 100644 --- a/systems/jeeves/configuration.nix +++ b/systems/jeeves/configuration.nix @@ -63,6 +63,7 @@ id = "l62ul-lpweo"; # cspell:disable-line path = "/ZFS/Media/Notes"; devices = [ + "bob" "phone" "rhapsody-in-green" ]; @@ -72,6 +73,7 @@ id = "6uppx-vadmy"; # cspell:disable-line path = "/ZFS/Storage/Syncthing/books"; devices = [ + "bob" "phone" "rhapsody-in-green" ]; @@ -81,6 +83,7 @@ id = "4ckma-gtshs"; # cspell:disable-line path = "/ZFS/Storage/Syncthing/important"; devices = [ + "bob" "phone" "rhapsody-in-green" ]; @@ -90,6 +93,7 @@ id = "vprc5-3azqc"; # cspell:disable-line path = "/ZFS/Storage/Syncthing/music"; devices = [ + "bob" "phone" "rhapsody-in-green" ]; @@ -98,7 +102,10 @@ "projects" = { id = "vyma6-lqqrz"; # cspell:disable-line path = "/ZFS/Storage/Syncthing/projects"; - devices = [ "rhapsody-in-green" ]; + devices = [ + "bob" + "rhapsody-in-green" + ]; fsWatcherEnabled = true; }; }; diff --git a/systems/rhapsody-in-green/configuration.nix b/systems/rhapsody-in-green/configuration.nix index 939e091..d6fcd73 100644 --- a/systems/rhapsody-in-green/configuration.nix +++ b/systems/rhapsody-in-green/configuration.nix @@ -55,6 +55,7 @@ id = "l62ul-lpweo"; # cspell:disable-line path = "/home/richie/notes"; devices = [ + "bob" "phone" "jeeves" ]; @@ -64,6 +65,7 @@ id = "6uppx-vadmy"; # cspell:disable-line path = "/home/richie/books"; devices = [ + "bob" "phone" "jeeves" ]; @@ -73,6 +75,7 @@ id = "4ckma-gtshs"; # cspell:disable-line path = "/home/richie/important"; devices = [ + "bob" "phone" "jeeves" ]; @@ -82,13 +85,17 @@ id = "vprc5-3azqc"; # cspell:disable-line path = "/home/richie/music"; devices = [ + "bob" "phone" "jeeves" ]; "projects" = { id = "vyma6-lqqrz"; # cspell:disable-line path = "/home/richie/projects"; - devices = [ "jeeves" ]; + devices = [ + "bob" + "jeeves" + ]; fsWatcherEnabled = true; }; fsWatcherEnabled = true; diff --git a/users/richie/global/syncthing_base.nix b/users/richie/global/syncthing_base.nix index 28d7cea..bd1e78e 100644 --- a/users/richie/global/syncthing_base.nix +++ b/users/richie/global/syncthing_base.nix @@ -11,6 +11,7 @@ phone.id = "LTGPLAE-M4ZDJTM-TZ3DJGY-SLLAVWF-CQDVEVS-RGCS75T-GAPZYK3-KUM6LA5"; # cspell:disable-line jeeves.id = "7YQ4UEW-OPQEBH4-6YKJH4B-ZCE3SAX-5EIK5JL-WJDIWUA-WA2N3D5-MNK6GAV"; # cspell:disable-line rhapsody-in-green.id = "INKUNKN-KILXGL5-2TQ5JTH-ORJOLOM-WYD2PYO-YRDLQIX-3AKZFWT-ZN7OJAE"; # cspell:disable-line + bob.id = "YP6UYKF-KFZ3FG3-5XM3XM3-5Q24AZS-LZK67PN-LAERKU2-K4WMYBH-N57ZBA5"; # cspell:disable-line }; }; };