Properly use x-forwarded-proto with redirects in the webui, related to #347
(cherry picked from commit a4f46ced49)
This commit is contained in:
@@ -71,7 +71,7 @@ http {
|
||||
location {{ WEB_WEBMAIL }} {
|
||||
rewrite ^({{ WEB_WEBMAIL }})$ $1/ permanent;
|
||||
rewrite ^{{ WEB_WEBMAIL }}/(.*) /$1 break;
|
||||
proxy_set_header Host $host;
|
||||
include /etc/nginx/proxy.conf;
|
||||
proxy_pass http://$webmail;
|
||||
}
|
||||
{% endif %}
|
||||
@@ -83,8 +83,8 @@ http {
|
||||
|
||||
location ~ {{ WEB_ADMIN }}/(ui|static) {
|
||||
rewrite ^{{ WEB_ADMIN }}/(.*) /$1 break;
|
||||
include /etc/nginx/proxy.conf;
|
||||
proxy_set_header X-Forwarded-Prefix {{ WEB_ADMIN }};
|
||||
proxy_set_header Host $host;
|
||||
proxy_pass http://$admin;
|
||||
}
|
||||
|
||||
@@ -102,6 +102,7 @@ http {
|
||||
rewrite ^/webdav/(.*) /$1 break;
|
||||
auth_request /internal/auth/basic;
|
||||
auth_request_set $user $upstream_http_x_user;
|
||||
include /etc/nginx/proxy.conf;
|
||||
proxy_set_header X-Remote-User $user;
|
||||
proxy_set_header X-Script-Name /webdav;
|
||||
proxy_pass http://$webdav;
|
||||
|
||||
Reference in New Issue
Block a user