diff options
Diffstat (limited to 'modules/system/tailscale.nix')
| -rw-r--r-- | modules/system/tailscale.nix | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/modules/system/tailscale.nix b/modules/system/tailscale.nix new file mode 100644 index 0000000..994c7a8 --- /dev/null +++ b/modules/system/tailscale.nix @@ -0,0 +1,14 @@ +{ + flake.modules.nixos.tailscale = { config, ... }: { + services.tailscale.enable = true; + networking.nftables.enable = true; + networking.firewall = { + enable = true; + trustedInterfaces = [ config.services.tailscale.interfaceName ]; + allowedUDPPorts = [ config.services.tailscale.port ]; + }; + systemd.services.tailscaled.serviceConfig.Environment = [ + "TS_DEBUG_FIREWALL_MODE=nftables" + ]; + }; +} |
