node-red / nginx.conf
2Btainment's picture
Initial Einswarm Node-RED Docker Space (nginx:7860, adminAuth, BMC async)
b2d5d3a verified
Raw History Blame Contribute Delete
2.45 kB
worker_processes 1;
error_log /tmp/nginx-error.log warn;
pid /tmp/nginx.pid;
events { worker_connections 1024; }
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
access_log /tmp/nginx-access.log;
sendfile on;
keepalive_timeout 65;
client_max_body_size 50m;
client_body_temp_path /tmp/nginx_client_body;
proxy_temp_path /tmp/nginx_proxy;
fastcgi_temp_path /tmp/nginx_fastcgi;
uwsgi_temp_path /tmp/nginx_uwsgi;
scgi_temp_path /tmp/nginx_scgi;
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
server {
listen 7860;
server_name _;
location = /healthz {
proxy_pass http://127.0.0.1:1880/;
proxy_set_header Host $host;
proxy_hide_header X-Frame-Options;
proxy_hide_header Cross-Origin-Resource-Policy;
add_header Content-Security-Policy "frame-ancestors 'self' https://huggingface.co https://*.hf.space;" always;
add_header Cache-Control "no-store";
}
location /einswarm-static/ {
alias /einswarm/;
expires 1d;
add_header Cache-Control "public";
add_header Content-Security-Policy "frame-ancestors 'self' https://huggingface.co https://*.hf.space;" always;
}
location / {
proxy_pass http://127.0.0.1:1880;
proxy_http_version 1.1;
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;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header Authorization $http_authorization;
proxy_set_header Cookie $http_cookie;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_pass_header Set-Cookie;
proxy_hide_header X-Frame-Options;
proxy_hide_header Cross-Origin-Resource-Policy;
add_header Content-Security-Policy "frame-ancestors 'self' https://huggingface.co https://*.hf.space;" always;
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;
proxy_buffering off;
}
}
}