首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > 编程 >

nginx + resin筹建

2013-10-22 
nginx + resin搭建默认8080,可修改?4:启动resinworks/resin-3.0.23/bin/http.sh start浏览器中输入host:端

nginx + resin搭建

默认8080,可修改

?

4:启动resin

works/resin-3.0.23/bin/http.sh start

浏览器中输入host:端口,能打开resin欢迎界面说明resin配置成功

nginx + resin筹建

?

?

5:整合nginx, resin

使用nginx的proxy功能,将请求转发给resin

修改nginx的配置文件nginx.conf

?

?程序代码

server {

? ? ? ? listen ? ? ? 80;

? ? ? ? server_name ?www.qinghuis.com;

?

? ? ? ? error_page ? 500 502 503 504 ?/50x.html;

? ? ? ? location = /50x.html {

? ? ? ? ? ? root ? html;

? ? ? ? }

?

?

? ? ? ? location / {

? ? ? ? ? ? ?access_log on;

? ? ? ? ? ? ?proxy_pass http://127.0.0.1:8082;

? ? ? ? ? ? ?proxy_set_header X-Real-IP $remote_addr; ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ??

? ? ? ? ? ? ?proxy_set_header Host $host; ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ??

? ? ? ? ? ? ?proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?client_max_body_size ? ?10m; ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ??

? ? ? ? ? ? ?client_body_buffer_size 128k; ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?

? ? ? ? } ? ? ??

} ? ? ? ?

?

修改配置后重启nginx,访问nginx则会跳转至resin欢迎页

?

?

?

热点排行