From 1deb0047b9428ec3e87e2b46db790a8159769b7c Mon Sep 17 00:00:00 2001 From: schererleander Date: Fri, 24 Oct 2025 18:59:42 +0200 Subject: added an option to make site the default site --- flake.nix | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index 2800ac7..c88a917 100644 --- a/flake.nix +++ b/flake.nix @@ -65,6 +65,12 @@ description = "Domain to serve."; }; + default = lib.mkOption { + type = types.bool; + default = false; + description = "Make this vhost the default for nginx."; + }; + package = mkOption { type = types.package; description = "Package whose /share/web contains the built site."; @@ -100,6 +106,7 @@ in { root = "${cfg.package}/share/web"; + default = cfg.default; locations."/" = { tryFiles = "$uri $uri/ /index.html"; -- cgit v1.3.1