nginx基本配置
nginx设置反向代理
本篇文章使用IIS 6.0 及nginx 1.15.7
1:安装nginx
官方网址链接:http://nginx.org/en/
下载windows版本进行安装
2:IIS设置网站
网站1:
网站2:
3:nginx配置文件
配置文件在nginx安装文件夹下的conf文件夹下的nginx.conf
events { worker_connections 1024; } http { upstream cxd { server 127.0.0.1:8080; server 127.0.0.1:8090; } server { listen 8010; server_name 127.0.0.1; location / { proxy_pass http://cxd; root html; index index.html index.htm; } error_page 500 502 503 504 /50x.html; location = /50x.html { root cxd; } } }
4:运行nginx
nginx的基本设置完成
使用cmd类软件定位至nginx文件夹,启用nginx.exe
这样就成功了
然后赶快打开nginx服务器对应的端口号访问吧
posted on 2018-12-24 15:48 koukouforyou 阅读(121) 评论(0) 收藏 举报