From d91013096244ab0026dfc0f53d14ea0bbd3a8d79 Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Thu, 21 Apr 2022 19:25:59 -0700 Subject: syncthing: configure the keys for tahoe --- modules/services/syncthing/default.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'modules/services/syncthing') diff --git a/modules/services/syncthing/default.nix b/modules/services/syncthing/default.nix index bbd4fb9..ea8c4d6 100644 --- a/modules/services/syncthing/default.nix +++ b/modules/services/syncthing/default.nix @@ -1,5 +1,7 @@ { config, pkgs, lib, ... }: -let cfg = config.my.services.syncthing; +let + cfg = config.my.services.syncthing; + secrets = config.age.secrets; in { options.my.services.syncthing = with lib; { enable = mkEnableOption "syncthing service"; @@ -9,9 +11,11 @@ in { services.syncthing = { enable = true; openDefaultPorts = true; - user = users.users.fcuny; + user = "fcuny"; group = "users"; - dataDir = "${users.users.fcuny.home}/.syncthing"; + dataDir = "/home/fcuny/.local/state/syncthing"; + cert = secrets."syncthing/cert".path; + key = secrets."syncthing/key".path; }; }; } -- cgit 1.4.1