This commit is contained in:
SebastianStork 2025-06-13 16:54:03 +02:00
parent e285ab3183
commit 9fb4a18ee5
11 changed files with 22 additions and 44 deletions

View file

@ -6,7 +6,7 @@
}:
let
cfg = config.custom.services.syncthing;
tsCfg = config.custom.services.tailscale;
tailscaleCfg = config.custom.services.tailscale;
in
{
options.custom.services.syncthing = {
@ -21,7 +21,7 @@ in
config = lib.mkIf cfg.enable {
assertions = [
{
assertion = tsCfg.enable;
assertion = tailscaleCfg.enable;
message = "syncthing requires tailscale";
}
];
@ -44,7 +44,7 @@ in
|> lib.mapAttrs (
name: value: {
id = value.config.custom.services.syncthing.deviceId;
addresses = [ "tcp://${name}.${tsCfg.domain}:22000" ];
addresses = [ "tcp://${name}.${tailscaleCfg.domain}:22000" ];
}
);