简体   繁体   English

乘客似乎不知道VirtualHost是Rails应用程序

[英]Passenger doesn't seem to know the VirtualHost is a rails app

I've configured Apache 2.2 with a VirtualHost for a Ruby on Rails (2.3.14) application. 我为Ruby on Rails(2.3.14)应用程序配置了带有VirtualHost的Apache 2.2。

However, when I visit the url for the website I'm presented with a directory listing. 但是,当我访问网站的URL时,会看到目录列表。

I've checked that passenger (5.0.9) is loaded by Apache (it is) and I've got the loglevel set to 4 so I can see what passenger is doing. 我检查了Apache是​​否加载了乘客(5.0.9),并且将日志级别设置为4,以便可以看到乘客在做什么。 It starts up and indicates that it is listening for requests. 它启动并指示它正在侦听请求。

However, it would appear that passenger is not being invoked when the website is visited. 但是,当访问该网站时,似乎没有调用乘客。

How does passenger know that it needs to handle this virtualhost? 乘客如何知道需要处理此虚拟主机?

Thanks 谢谢

Solution: 解:

The rails application did not have a config.ru file. Rails应用程序没有config.ru文件。

After pinching one off the web for rails 2.3 the application now appears instead of the directory listing. 在将其中一个从Rails 2.3上拖下后,现在将显示该应用程序,而不是目录列表。

It appears from the passenger documentation this this file is used by rack to fire up instances of the application. 从乘客文档中可以看到,机架使用此文件来启动应用程序实例。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在 Apache 上设置 Rails 应用程序与乘客 - Rails 似乎没有加载 - Setting up Rails app on Apache with passenger - Rails doesn't seem to load 乘客似乎没有在奔跑(Capistrano / Rails / Apache / Ubuntu) - Passenger doesn't seem to be running (Capistrano/Rails/Apache/Ubuntu) Apache with Passenger不加载Rails应用程序 - Apache with Passenger doesn't load Rails app ***错误:Phusion Passenger似乎没有运行 - *** ERROR: Phusion Passenger doesn't seem to be running 警告:Apache似乎没有使用'prefork','worker'或'event'MPM进行编译-Rails-Apache2-Passenger - WARNING: Apache doesn't seem to be compiled with the 'prefork', 'worker' or 'event' MPM - Rails - Apache2 - Passenger Apache上的乘客:“似乎没有在运行”,应用页面显示403; 接下来是什么? - Passenger on Apache: “doesn't seem to be running”, app page gives 403; what next? 乘客的VirtualHost问题(mod_rails) - VirtualHost problem with passenger (mod_rails) Rails 7 + shakapacker 应用程序中似乎没有加载 Vue3 - Vue3 doesn't seem to be loaded in Rails 7 + shakapacker app Rails乘客无法正确启动 - rails passenger doesn't boot correctly CentOS ***错误:Phusion Passenger似乎没有运行 - CentOS *** ERROR: Phusion Passenger doesn't seem to be running
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM