location / { root D:/rx/dev/trunk/client/game/bin/;

server {

listen 80;

server_name localhost;

#charset koi8-r;

#access_log logs/host.access.log main;

location / {

root D:/rx/dev/trunk/client/game/bin/;

root ../../client;

index index.html index.htm;

autoindex on;

#autoindex_format json;

#autoindex_localtime on;

add_header Access-Control-Allow-Origin *;

}

#error_page 404 /404.html;

redirect server error pages to the static page /50x.html

error_page 500 502 503 504 /50x.html;

location = /50x.html {

root ..;

}

proxy the PHP scripts to Apache listening on 127.0.0.1:80

#location ~ \.php$ {

proxy_pass http://127.0.0.1;

#}

pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000

#location ~ \.php$ {

root ..;

fastcgi_pass 127.0.0.1:9000;

fastcgi_index index.php;

fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;

include fastcgi_params;

#}

deny access to .htaccess files, if Apache's document root

concurs with nginx's one

#location ~ /\.ht {

deny all;

#}

}

相关推荐
fxshy10 小时前
ai聊天流式响应,阻塞式和流式响应 nginx遇到的坑
运维·javascript·nginx
Sonetto199920 小时前
Nginx 反向代理,啥是“反向代理“啊,为啥叫“反向“代理?而不叫“正向”代理?它能干哈?
运维·前端·nginx
白总Server1 天前
Nginx 中间件
大数据·linux·运维·服务器·nginx·bash·web
异常君2 天前
HTTP头中的Accept-Encoding与Content-Encoding深度剖析
后端·nginx·http
生命有所坚持而生存可以随遇而安2 天前
https nginx 负载均衡配置
服务器·nginx·负载均衡
Python私教2 天前
CentOS 7 基于 Nginx 的 HTML 部署全流程指南
nginx·centos·html
五号厂房2 天前
客户端收到413 Request Entity Too Large错误该如何解决?
nginx
大胆刁民3 天前
nginx
nginx
王者鳜錸3 天前
2024从Maven-MySQL-Nginx部署
mysql·nginx·maven
中国lanwp3 天前
Pingora vs. Nginx vs. 其他主流代理服务器性能对比
运维·nginx