nixos-configuration/modules/tailscale.nix

20 lines
285 B
Nix
Raw Normal View History

2023-12-04 22:24:43 +01:00
{
pkgs,
config,
lib,
...
}: let
cfg = config.my.tailscale;
in {
options.my.tailscale = {
enable = lib.mkEnableOption "enable tailscale vpn";
};
config = lib.mkIf cfg.enable {
services.tailscale = {
enable = true;
openFirewall = true;
};
};
}