2011-03-28 74 views
1

我正在使用Passenger with Rails 3.0.5和Ruby 1.8.7。Rails 3.0.5:Bundler说它会使用Rack1.2.2,但乘客会抛出一个GemNotFound错误

它工作正常,直到我不记得一些变化。

我打了bundle install,它说它会使用Rack 1.2.2,但Bundler仍然返回GemNotFound Rack 1.2.2。

当我点击find/-name "rack"时,它显示Rack 1.2.2已安装到所有的目录,似乎它已安装。

我明确要求我的Gemfile中的Gem Rack 1.2.2,这也没有帮助。

通过bundle config path /dir/to/gems输入gemdir并没有帮助。

谁能给我正确的建议或解决这个问题?

感谢,

你的,

Joern。

回答

1

你的乘客使用另一个Ruby安装。 manualy设置在NGINX_FOLDER/conf/nginx.conf

http { 
    passenger_ruby /path/to/you/ruby/folder; 
    ... 
} 

知道你的Ruby文件夹使用这个命令:

which ruby 

UPD

对于Apache(可以正式乘客Apache模块文档阅读)http://www.modrails.com/documentation/Users%20guide%20Apache.html#_unloading_disabling_phusion_passenger_from_apache_without_uninstalling_it 。只需设置:

PassengerRuby /path/to/your/ruby/folder 
+0

我使用的Apache2客运 – 2011-03-28 21:24:48

+0

然后改变它在appache配置:) – fl00r 2011-03-28 21:40:20

+0

'PassengerRuby在/ usr/bin中/红宝石...' – fl00r 2011-03-29 07:23:16

相关问题