2023-09-21 15:11:59 +02:00
|
|
|
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
|
|
|
|
location __PATH__/ {
|
|
|
|
|
2023-09-21 16:29:54 +02:00
|
|
|
# This allows to pass arguments to the httpsh script
|
|
|
|
set $path $1;
|
|
|
|
set $req $path;
|
|
|
|
if ($path ~* ^(\/ws)?$) {
|
|
|
|
set $req $path?arg=$remote_addr;
|
|
|
|
}
|
2023-09-21 15:11:59 +02:00
|
|
|
|
2023-09-21 16:29:54 +02:00
|
|
|
proxy_http_version 1.1;
|
|
|
|
proxy_set_header Host $host;
|
|
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
|
|
proxy_set_header Connection "upgrade";
|
2023-09-21 15:11:59 +02:00
|
|
|
|
2023-09-21 16:29:54 +02:00
|
|
|
proxy_pass http://127.0.0.1:__PORT__$req;
|
2023-09-21 15:11:59 +02:00
|
|
|
|
2023-12-05 15:52:13 +01:00
|
|
|
proxy_read_timeout 3600s; # dont kill connection after 60s of inactivity
|
|
|
|
|
2023-09-21 15:11:59 +02:00
|
|
|
# Include SSOWAT user panel.
|
|
|
|
include conf.d/yunohost_panel.conf.inc;
|
|
|
|
}
|