我對任何一個曾經說過任何與「在rails應用上部署ruby應用程序都很簡單」相等的人感到憤怒。不,這不對。這是我所做過的最難的事情,我開發了操作系統。在Ubuntu上設置Passenger Phusion 11.04
噢。現在已經結束了。我終於得到了乘客的安裝(使用低音ackwards安裝過程中),並安裝到說:
請編輯您的Apache配置文件,並添加這些行:
LoadModule passenger_module /usr/local/rvm/gems/[email protected]/gems/passenger-3.0.8/ext/apache2/mod_passenger.so
PassengerRoot /usr/local/rvm/gems/[email protected]/gems/passenger-3.0.8
PassengerRuby /usr/local/rvm/wrappers/[email protected]/ruby
假設你有一個Rails應用程序/某處。虛擬主機添加到您的 Apache配置文件和DocumentRoot的設置/地方/市民:
<VirtualHost *:80>
ServerName www.yourhost.com
DocumentRoot /somewhere/public # <-- be sure to point to 'public'!
<Directory /somewhere/public>
AllowOverride all # <-- relax Apache security settings
Options -MultiViews # <-- MultiViews must be turned off
</Directory>
</VirtualHost>
我就把這二者都在/etc/apache2/apache2.conf中,當我試着啓動Apache它說我把這個垃圾放在哪一行上的錯誤。非常感謝幫助。我快到了,我能感覺到它!
尼克
您可能應該在您的問題 – mikezter
中包含錯誤消息以啓動您的虛擬主機不應該在您的apache2.conf中 - 應該是/ etc/apache2/sites-available/railsapp參考[Ubuntu apache config guide]( https://help.ubuntu.com/11.04/serverguide/C/httpd.html#http-configuration) –