Home  >  Q&A  >  body text

ruby-on-rails - Rails + Passengen + Nginx deployment, error 403 Forbidden?

Basically configured according to the tutorial, but there is indeed a 403 error when accessing, and then check the nginx log, the error is as follows:

2015/03/25 04:34:51 [error] 2269#0: *1 directory index of "/home/rails-deploy/project/" is forbidden, client: xxx.xxx.xxx.xxx, server: example.cn, request: "GET / HTTP/1.1", host: "example.cn"

After creating a new index.html file in the project directory, it can be accessed, which proves that there is no problem with the permissions of the project directory.

I also saw someone encountering a similar problem on rubychina, but there is no actual solution: RubyChina

I would like to ask if anyone has encountered this kind of problem and solved it.

某草草某草草2685 days ago596

reply all(2)I'll reply

  • 为情所困

    为情所困2017-05-16 17:26:43

    Have you completed the following steps?
    rails generate secret key

    reply
    0
  • PHP中文网

    PHP中文网2017-05-16 17:26:43

    Is your problem solved now?

    reply
    0
  • Cancelreply