From 6b5f86c9ab6c928ccacc50f01e4dbfcf68a4a0ca Mon Sep 17 00:00:00 2001 From: Kabbone Date: Tue, 4 Jun 2024 21:06:44 +0200 Subject: [PATCH] dmz: services: nginx: add recommendedSettings and fix Hydra --- modules/services/dmz/hydra.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/modules/services/dmz/hydra.nix b/modules/services/dmz/hydra.nix index 0905fb7..8ba371e 100644 --- a/modules/services/dmz/hydra.nix +++ b/modules/services/dmz/hydra.nix @@ -18,6 +18,10 @@ }; nginx = { enable = true; + recommendedProxySettings = true; + recommendedTlsSettings = true; + recommendedGzipSettings = true; + recommendedOptimisation = true; virtualHosts = { "home.opel-online.de" = { enableACME = true; @@ -28,7 +32,12 @@ "hydra.home.opel-online.de" = { useACMEHost = "home.opel-online.de"; forceSSL = true; - locations."/".proxyPass = "http://localhost:3000"; + locations."/" = { + proxyPass = "http://localhost:3000"; + extraConfig = '' + proxy_set_header X-Forwarded-Port 443; + ''; + }; }; "cache.home.opel-online.de" = { useACMEHost = "home.opel-online.de";