diff options
Diffstat (limited to 'nixos/hosts/tente/headscale.nix')
-rw-r--r-- | nixos/hosts/tente/headscale.nix | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/nixos/hosts/tente/headscale.nix b/nixos/hosts/tente/headscale.nix index 6faea12..fe7e12b 100644 --- a/nixos/hosts/tente/headscale.nix +++ b/nixos/hosts/tente/headscale.nix @@ -5,6 +5,9 @@ let in { options.headscale = { + port = lib.mkOption { + type = lib.types.int; + }; domain = lib.mkOption { type = lib.types.str; }; @@ -14,7 +17,7 @@ in services = { headscale = { enable = true; - port = 8080; + port = cfg.port; # TODO: make dataDir configurable and set it to /srv/ settings = { server_url = "https://${cfg.domain}"; @@ -26,7 +29,7 @@ in enableACME = true; forceSSL = true; locations."/" = { - proxyPass = "http://localhost:${toString config.services.headscale.port}"; + proxyPass = "http://localhost:${toString cfg.port}"; proxyWebsockets = true; }; }; |