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;

#}

}

相关推荐
bitbitDown6 小时前
记录nginx学习
nginx
showmethetime12 小时前
优化nginx参数(基本通用参数)
运维·nginx
YUNYINGXIA1 天前
Nginx+keepalived主从,双主架构
网络·nginx·keepalived
Hello.Reader1 天前
NGINX 四层共享内存区同步模块实战 `ngx_stream_zone_sync_module`
运维·nginx
北城笑笑1 天前
Server 11 ,⭐通过脚本在全新 Ubuntu 系统中安装 Nginx 环境,安装到指定目录( 脚本安装Nginx )
linux·运维·前端·nginx·ubuntu
jarenyVO2 天前
Nginx全面深入学习目录
运维·学习·nginx
笨手笨脚の2 天前
Nginx-2 详解处理 Http 请求
运维·网络协议·nginx·http
苹果醋32 天前
SpringCloud Alibaba场景实践(Nacos篇)
java·运维·spring boot·mysql·nginx
Hello.Reader2 天前
NGINX 四层上游模块`ngx_stream_upstream_module` 实战指南
运维·nginx
hie988942 天前
[nginx]反向代理grpc
运维·nginx·iphone