aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorGuillaume Horel <guillaume.horel@gmail.com>2018-12-29 14:50:47 -0500
committerGuillaume Horel <guillaume.horel@gmail.com>2018-12-29 14:50:47 -0500
commit714f3a8138e6c5e2201a9c6c1fa2f67a360eb0b3 (patch)
tree85a9a7e03b880c4d6d5b69442d337390a1bf039b /README.md
parentb05e67549c0ea2d1c66b33a09f9d06aa35727702 (diff)
downloadfamille-flask-714f3a8138e6c5e2201a9c6c1fa2f67a360eb0b3.tar.gz
fix nginx config
Diffstat (limited to 'README.md')
-rw-r--r--README.md6
1 files changed, 5 insertions, 1 deletions
diff --git a/README.md b/README.md
index b550c4a..2c743bb 100644
--- a/README.md
+++ b/README.md
@@ -20,6 +20,10 @@ Nginx config
auth_request /validate;
auth_request_set $auth_user $upstream_http_x_remote_user;
+ error_page 401 = @error_401;
+
+ location @error_401 {
+ return 302 https://id.horel.org/login?next=$schem://$http_host$request_uri;
location = /validate {
internal;
@@ -29,7 +33,7 @@ Nginx config
proxy_set_header X-Original-URI $request_uri;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
- proxy_pass http://127.0.0.1:8080/;
+ proxy_pass http://127.0.0.1:8080/validate;
}
}