u.twoha.cc/nginx.conf
2024-09-19 21:26:20 -05:00

34 lines
1,005 B
Nginx Configuration File

pid /tmp/pid.pid;
daemon off;
events {}
http {
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /dev/stdout main;
server {
listen 8080;
server_name localhost;
root /tmp/2h;
location / {
try_files $uri $uri.html $uri/ =404;
autoindex on;
types {
text/html html;
text/css css;
application/javascript js;
image/x-icon ico;
}
}
location /_/ {
proxy_pass http://127.0.0.1:5000;
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;
}
}
}