I am getting a 403 when I try to access my rails app running on top of nginx and passenger. Here is the error from the log file:
2013/05/09 13:52:34 [error] 27787#0: *1 directory index of "/var/www/Tread-Forth/current/public/" is forbidden, client: 192.249.16.60, server: treadforth.com, request: "GET / \
HTTP/1.1", host: "www.treadforth.com"
This problem occurs even when I run nginx as root, so I don't think it is a permissions problem. I think the problem is that I do not have passenger_ruby
or passenger_root
defined in my nginx.conf file. The problem is, I don't know where these values go in the config file, and I don't know what their values should be. Any help would be great. Here is my conf file for reference:
worker_processes 1;
events {
worker_connections 1024;
}
http {
#passenger_root /usr/local/bin/passenger;
#passenger_ruby /usr/local/bin/ruby;
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
server {
listen 80;
server_name .treadforth.com;
root /var/www/Tread-Forth/current/public;
passenger_enabled on;
}
}
You can see the commented out version of passenger_root and passenger_ruby I have tried. When I uncomment these, nginx fails to start but does not produce any error messages.