Redmine RailsBaseURI

时间:2013-01-14 10:36:43

标签: linux redmine

我使用此方法安装了Redmine http://www.redmine.org/projects/redmine/wiki/HowTo_Install_Redmine_using_Debian_package

ln -s /usr/share/redmine/public /var/www/redmine

chown -R www-data:www-data /var/www/redmine
echo "RailsBaseURI /redmine" > /etc/apache2/sites-available/redmine
a2ensite redmine
/etc/init.d/apache2 reload
/etc/init.d/apache2 restart

但我得到以下消息重启apache2。

Syntax error on line 1 of /etc/apache2/sites-enabled/redmine:
Invalid command 'RailsBaseURI', perhaps misspelled or defined by a module not included in the server configuration
Action 'configtest' failed.
The Apache error log may have more information.
 failed!

祝福

3 个答案:

答案 0 :(得分:15)

用@favoretti的建议部分解决了:

#apt-get install libapache2-mod-passenger
#/etc/init.d/apache2 reload
Reloading web server config: apache2.

意味着错误消失

答案 1 :(得分:2)

我是因为谷歌搜索“无效命令'RailsBaseURI'而来的。我这里没有答案,但我后来发现这个错误是由于没有启用乘客造成的。

假设您已经安装了它,则可以使用sudo a2enmod passenger启用乘客。

答案 2 :(得分:0)

您应该检查乘客配置。

1.是否在/ etc / apache2 / mods-enabled中链接了passenger.conf和passenger.load

/etc/apache2/mods-enabled# ls passenger.*
passenger.conf
passenger.load

2.检查配置文件:passenger.conf / passenger.load

passenger.conf:

<IfModule mod_passenger.c>
  PassengerRoot /home/hao/.rvm/gems/ruby-1.9.3-p448@rails4.0/gems/passenger-4.0.14
  PassengerDefaultRuby /home/hao/.rvm/wrappers/ruby-1.9.3-p448@rails4.0/ruby
</IfModule>

passenger.load:

LoadModule passenger_module /home/hao/.rvm/gems/ruby-1.9.3-p448@rails4.0/gems/passenger-4.0.14/buildout/apache2/mod_passenger.so

3.根据official doc

,乘客是否会受到影响
Restart your web server and run:
passenger-memory-stats
相关问题