From 415fd7f076389d43424eebca3f5f318c1f14c08f Mon Sep 17 00:00:00 2001 From: Max Date: Sat, 10 Aug 2024 02:58:56 +0200 Subject: [PATCH] lib/nginx: use dynamic proxy targets in proxyGhost --- lib/nginx.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/nginx.nix b/lib/nginx.nix index 4f0f72b..d2be4cf 100644 --- a/lib/nginx.nix +++ b/lib/nginx.nix @@ -36,7 +36,8 @@ proxyGhost = scheme: target: basic // { locations."/".extraConfig = '' - proxy_pass ${scheme}://${target}; + set $nix_proxy_ghost_target "${scheme}://${target}"; + proxy_pass $nix_proxy_ghost_target; proxy_set_header Host ${target}; proxy_set_header Referer ${scheme}://${target}; proxy_cookie_domain ${target} domain.invalid;