events { worker_connections 64; multi_accept on; } http { # 配置 HTTP 服务 access_log log/access.log combined; # 日志文件的位置和格式 error_log log/error.log error; types { text/html html; } upstream ismism { # 服务 server 127.0.0.1:728; keepalive 2; } server { listen 80 default_server; root ui; # 静态文件的根目录 location = / { # "http://localhost" try_files /index.html =444; } # "http://localhost/mod/marked.js" -> /ui/mod/marked.js location /mod {} # "http://localhost/q?que="adm" -> http://127.0.0.1:728/q?que="adm" location /q { proxy_pass http://ismism; } location /p { proxy_pass http://ismism; } } }