mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-02 05:44:03 +02:00
Improve
This commit is contained in:
@@ -3,17 +3,24 @@ server {
|
|||||||
include /etc/nginx/includes/server_params.conf;
|
include /etc/nginx/includes/server_params.conf;
|
||||||
include /etc/nginx/includes/proxy_params.conf;
|
include /etc/nginx/includes/proxy_params.conf;
|
||||||
|
|
||||||
proxy_buffering off;
|
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
|
||||||
# Proxy pass
|
# Proxy pass
|
||||||
proxy_pass http://localhost:8080;
|
proxy_pass http://localhost:8080/;
|
||||||
rewrite ^%%ingress_entry%%/(.*)$ /$1 break;
|
rewrite ^%%ingress_entry%%/(.*)$ /$1 break;
|
||||||
|
|
||||||
|
# Disable buffering
|
||||||
|
proxy_buffering off;
|
||||||
|
proxy_request_buffering off;
|
||||||
|
|
||||||
# Next three lines allow websockets
|
# Next three lines allow websockets
|
||||||
proxy_http_version 1.1;
|
proxy_http_version 1.1;
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
proxy_set_header Connection "upgrade";
|
proxy_set_header Connection $connection_upgrade;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
|
||||||
set $today "";
|
set $today "";
|
||||||
if ($time_iso8601 ~ "^(\d{4}-\d{2}-\d{2})") {
|
if ($time_iso8601 ~ "^(\d{4}-\d{2}-\d{2})") {
|
||||||
|
|||||||
Reference in New Issue
Block a user