我正在使用我自己的rails项目来学习本教程:https://www.digitalocean.com/community/tutorials/how-to-deploy-a-rails-app-with-passenger-and-nginx-on-ubuntu-14-04
我一直在找到404 Nginx not found错误。打印出我收到的日志
error: 2014/11/16 14:08:13 [error] 20149#0: *29 "/home/rails/whattodo/public/index.html" is not found (2: No such file or directory), client: 70.52.174.228, server: , request: "GET / HTTP/1.1", host: "104.131.76.121"
2014/11/16 14:08:14 [error] 20149#0: *29 open() "/home/rails/whattodo/public/favicon.ico" failed (2: No such file or directory), client: 70.52.174.228, server: , request: "GET /favicon.ico HTTP/1.1", host: "104.131.76.121".
这是我的nginx文件:
server {
listen 80 defaultserver;
passengerenabled on;
passengerappenv development;
root /whattodo/public;
}
我将此索引文件添加到公用文件夹文件中,即使我认为没有必要,但仍然存在错误。任何你认为我应该去解决这个问题的帮助或指示都将不胜感激!