From 417cb3c5d3626c8235a1c434ac3a540ff916d35f Mon Sep 17 00:00:00 2001 From: "Casper V. Kristensen" Date: Sat, 12 Aug 2023 03:20:56 +0200 Subject: [PATCH] syncthing --- modules/desktop/default.nix | 1 + modules/desktop/syncthing.nix | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 modules/desktop/syncthing.nix diff --git a/modules/desktop/default.nix b/modules/desktop/default.nix index d311cb1..8f29767 100644 --- a/modules/desktop/default.nix +++ b/modules/desktop/default.nix @@ -4,6 +4,7 @@ ./network.nix ./ssh.nix ./sway.nix + ./syncthing.nix ]; environment.systemPackages = with pkgs; [ diff --git a/modules/desktop/syncthing.nix b/modules/desktop/syncthing.nix new file mode 100644 index 0000000..7391959 --- /dev/null +++ b/modules/desktop/syncthing.nix @@ -0,0 +1,27 @@ +{ config, ... }: { + # https://nixos.wiki/wiki/Syncthing + + services.syncthing = { + enable = true; + user = "caspervk"; + dataDir = "/home/caspervk"; + devices = { + "lambda" = { + id = "WES3JH4-S34HTC5-42YZHUJ-MX3Z6PA-PFO72KA-YIJMDOB-GQWZXZ3-I7BBTAS"; + addresses = [ "tcp://lambda.caspervk.net" ]; + }; + "S10e" = { id = "DWC6YHB-FRYKFHD-FPOUITV-7GL2WZH-RSFOJXR-PHYXDO7-74NLBUZ-TZENVAC"; }; + "zeta" = { id = "GQRNHAQ-MMRQYMD-P4RCA6I-5DJ3HXO-J2N2GVP-UGI55YR-HD3EYSO-ERU5QQV"; }; + }; + folders = { + "keepass" = { + path = "~/keepass"; + devices = [ "lambda" "S10e" "zeta" ]; + }; + "sync" = { + path = "~/sync"; + devices = [ "lambda" "zeta" ]; + }; + }; + }; +}