From dced397f2fec389769e9d11963246bf919c9ea6d Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Thu, 16 Mar 2017 17:29:28 +0100 Subject: Does proxy_set_header just set a default? --- bragi.nix | 6 +----- custom/ymir-nginx.nix | 5 ++++- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/bragi.nix b/bragi.nix index 6f0062d2..36ac556b 100644 --- a/bragi.nix +++ b/bragi.nix @@ -382,12 +382,8 @@ in rec { } location /bar/ { - map $http_AppRoot $approot { - default $http_AppRoot; - ''' $host/bar; - } proxy_pass http://[::1]:8082; - proxy_set_header AppRoot $approot; + proxy_set_header AppRoot $host/bar; } } ''; diff --git a/custom/ymir-nginx.nix b/custom/ymir-nginx.nix index 3953176f..bf0c8e67 100644 --- a/custom/ymir-nginx.nix +++ b/custom/ymir-nginx.nix @@ -161,7 +161,10 @@ in { auth_basic_user_file /srv/www/bragi/htpasswd; proxy_pass http://bragi.asgard.yggdrasil; - proxy_set_header AppRoot $host; + + location /bar/ { + proxy_set_header AppRoot $host/bar; + } } } ''; -- cgit v1.2.3