Create nginx-proxy.conf

This commit is contained in:
Darren 2022-11-01 16:01:50 +08:00 committed by GitHub
parent 25e26c36bc
commit 718f2df5f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

17
cockpit/nginx-proxy.conf Normal file
View file

@ -0,0 +1,17 @@
location /panel/ {
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Scheme $scheme;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://172.17.0.1:9090;
# Required for web sockets to function
proxy_http_version 1.1;
proxy_buffering off;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
# Pass ETag header from Cockpit to clients.
# See: https://github.com/cockpit-project/cockpit/issues/5239
gzip off;
}