diff options
Diffstat (limited to '')
-rw-r--r-- | modules/services/default.nix | 2 | ||||
-rw-r--r-- | modules/services/tailscale/default.nix | 13 |
2 files changed, 14 insertions, 1 deletions
diff --git a/modules/services/default.nix b/modules/services/default.nix index d34f57a..9a5338b 100644 --- a/modules/services/default.nix +++ b/modules/services/default.nix @@ -1 +1 @@ -{ ... }: { imports = [ ./ssh-server ]; } +{ ... }: { imports = [ ./ssh-server ./tailscale ]; } diff --git a/modules/services/tailscale/default.nix b/modules/services/tailscale/default.nix new file mode 100644 index 0000000..cad1cad --- /dev/null +++ b/modules/services/tailscale/default.nix @@ -0,0 +1,13 @@ +{ config, lib, ... }: +let cfg = config.my.services.tailscale; +in { + + options.my.services.tailscale = with lib; { + enable = mkEnableOption "tailscale configuration"; + }; + + config = lib.mkIf cfg.enable { + services.tailscale.enable = true; + networking.firewall.trustedInterfaces = [ "tailscale0" ]; + }; +} |