Remove tailscale serve/funncel module

This commit is contained in:
SebastianStork 2025-05-29 19:22:47 +02:00
parent 294bebdb98
commit 00adb88940
2 changed files with 1 additions and 47 deletions

View file

@ -0,0 +1,31 @@
{ config, lib, ... }:
let
cfg = config.custom.services.tailscale;
in
{
options.custom.services.tailscale = {
enable = lib.mkEnableOption "";
domain = lib.mkOption {
type = lib.types.nonEmptyStr;
default = "stork-atlas.ts.net";
};
ssh.enable = lib.mkEnableOption "";
exitNode.enable = lib.mkEnableOption "";
};
config = lib.mkIf cfg.enable {
sops.secrets."tailscale-auth-key" = { };
services.tailscale = {
enable = true;
authKeyFile = config.sops.secrets."tailscale-auth-key".path;
openFirewall = true;
useRoutingFeatures = if cfg.exitNode.enable then "server" else "client";
extraUpFlags = [ "--reset=true" ];
extraSetFlags = [
"--ssh=${lib.boolToString cfg.ssh.enable}"
"--advertise-exit-node=${lib.boolToString cfg.exitNode.enable}"
];
};
};
}