最近遇到一个 rails app 部署到 nginx 的问题 问题如下: 当使用 ssh 登录到服务器的时候,访问 web 一切正常 但是当从 ssh 退出的时候就会报 404 错误,这个是 nginx 错误 log
2012/02/19 19:49:50 [error] 13959#0: *227 "/home/fin/app/current/public/index.html" is not found (2: No such file or directory), client: 192.168.0.1, server: localhost, request: "GET / HTTP/1.1", host: "server_ip_address", referrer: "http://server_ip_address/users/sign_in"
2012/02/19 19:49:51 [error] 13959#0: *227 "/home/fin/app/current/public/index.html" is not found (2: No such file or directory), client: 192.168.0.1, server: localhost, request: "GET / HTTP/1.1", host: "server_ip_address", referrer: "http://server_ip_address/users/sign_in"
2012/02/19 19:49:52 [error] 13959#0: *227 "/home/fin/app/current/public/index.html" is not found (2: No such file or directory), client: 192.168.0.1, server: localhost, request: "GET / HTTP/1.1", host: "server_ip_address", referrer: "http://server_ip_address/users/sign_in"
2012/02/19 19:49:53 [error] 13959#0: *227 "/home/fin/app/current/public/index.html" is not found (2: No such file or directory), client: 192.168.0.1, server: localhost, request: "GET / HTTP/1.1", host: "server_ip_address", referrer: "http://server_ip_address/users/sign_in"
服务部署方式是 nginx + passenger【采用 nginx + unicorn 部署同样会出现这个问题】 rbenv, ruby1.9.2, rails3.1
有朋友遇到过类似的情况么?如需要可以再补出 nginx 配置信息,但是我觉得这个应该不是 nginx 配置的问题,因为当 ssh 登录后访问是正常的,寻 google,stackoverflow 无果
有遇到过类似问题的朋友么?提供一些解决问题的线索? 谢谢
ps 一些其他信息:服务器本身没有独立 ip,是内外网 ip 映射的