nixos/nginx: serve the status page on localhost servers

The status page is inaccessible by default, unless a virtual host is
added with a `server_name` that's not `localhost`.

This commit moves the status page configuration, so that
it's matched before the main server blocks.
This commit is contained in:
sandydoo 2023-04-28 07:20:36 +00:00
parent 2ed6b1b9f9
commit 2086b377cf
No known key found for this signature in database
GPG key ID: D1A763BC84F34603

View file

@ -256,8 +256,6 @@ let
${proxyCachePathConfig}
${vhosts}
${optionalString cfg.statusPage ''
server {
listen ${toString cfg.defaultHTTPListenPort};
@ -275,6 +273,8 @@ let
}
''}
${vhosts}
${cfg.appendHttpConfig}
}''}