mirror of
https://github.com/linuxserver/reverse-proxy-confs.git
synced 2025-07-05 20:41:32 -07:00
Hide Authorization header for syncthing
Add rest endpoint for syncthing
This commit is contained in:
parent
0eb569982b
commit
de4f1ccfbe
2 changed files with 25 additions and 0 deletions
|
@ -42,5 +42,17 @@ server {
|
||||||
set $upstream_proto http;
|
set $upstream_proto http;
|
||||||
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
||||||
|
|
||||||
|
proxy_hide_header Authorization;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ~ (/syncthing)?/rest {
|
||||||
|
include /config/nginx/proxy.conf;
|
||||||
|
include /config/nginx/resolver.conf;
|
||||||
|
set $upstream_app syncthing;
|
||||||
|
set $upstream_port 8384;
|
||||||
|
set $upstream_proto http;
|
||||||
|
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
||||||
|
|
||||||
|
proxy_hide_header Authorization;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,4 +28,17 @@ location ^~ /syncthing/ {
|
||||||
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
||||||
|
|
||||||
rewrite /syncthing(.*) $1 break;
|
rewrite /syncthing(.*) $1 break;
|
||||||
|
proxy_hide_header Authorization;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ^~ /syncthing/rest {
|
||||||
|
include /config/nginx/proxy.conf;
|
||||||
|
include /config/nginx/resolver.conf;
|
||||||
|
set $upstream_app syncthing;
|
||||||
|
set $upstream_port 8384;
|
||||||
|
set $upstream_proto http;
|
||||||
|
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
|
||||||
|
|
||||||
|
rewrite /syncthing(.*) $1 break;
|
||||||
|
proxy_hide_header Authorization;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue