Reverse proxy: Update config to set HTTP version as required for WebSockets (#2429)

Signed-off-by: Florian Hotze <dev@florianhotze.com>
pull/2432/head
Florian Hotze 2024-12-17 09:21:43 +01:00 committed by GitHub
parent 9bd97d7f1b
commit 9952883054
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 0 deletions

View File

@ -46,6 +46,7 @@ server {
add_header 'Access-Control-Allow-Methods' 'GET,POST,OPTIONS,PUT,DELETE,PATCH' always;
location / {
proxy_http_version 1.1;
proxy_pass http://localhost:8080/;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
@ -326,6 +327,7 @@ server {
add_header Strict-Transport-Security "max-age=31536000"; # Remove if using self-signed and are having trouble.
location / {
proxy_http_version 1.1;
proxy_pass http://localhost:8080/;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
@ -468,6 +470,7 @@ server {
add_header Set-Cookie X-OPENHAB-AUTH-HEADER=1;
location / {
proxy_http_version 1.1;
proxy_pass https://localhost:8443/; #Update the port number if needed
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;