1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
{ inputs, pkgs, config, lib, ... }:
let
syncthingConfig = import ../common/syncthing-config.nix { inherit inputs pkgs config lib; };
in {
age.identityPaths = [ "/Users/katja/.ssh/id_ed25519" ];
age.secrets = {
syncthing-key = {
file = ../../secrets + "/${config.networking.hostName}/syncthing/key.age";
owner = "katja";
};
syncthing-cert = {
file = ../../secrets + "/${config.networking.hostName}/syncthing/cert.age";
owner = "katja";
};
};
services = {
syncthing = {
enable = true;
user = "katja";
group = "staff";
key = config.age.secrets.syncthing-key.path;
cert = config.age.secrets.syncthing-cert.path;
dataDir = "/Users/katja";
devices = syncthingConfig.devices;
folders = syncthingConfig.folders;
};
};
}