0
我的Rails 2.3.8应用程序无法启动,因为缺少宝石:friendly_id。我得到了以下错误消息:在旅客中缺少宝石
Missing these required gems: friendly_id ~> 3.2.1 You're running: ruby 1.8.7.253 at /opt/ruby-enterprise-1.8.7-2010.02/bin/ruby rubygems 1.3.7 at /home/development/.gem/ruby/1.8, /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8 Run `rake gems:install` to install the missing gems.
其中development
是用户我运行的应用程序。
我发现在我的本地/usr/lib/ruby/gems/1.8/gems
中,我能够使用sudo gem install friendly_id
命令将gem安装到此目录中。
但我注意到在乘客检索宝石的路径上:/opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems
没有friendly_id
宝石。不过,如果没有sudo
,我无法运行命令。
现在我知道我必须将friendly_id
宝石安装到/opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems
目录中,但我无法弄清楚。
谢谢。