在Mac OS 10.6.8上安装Webistrano RAILS_ENV = production rake db:migrate失败

时间:2011-08-02 17:58:52

标签: ruby-on-rails install rake capistrano webistrano

我一直在尝试安装Webistrano。我已经安装了它所需的所有依赖项,包括Capistrano,如github wiki:https://github.com/peritor/webistrano/wiki/Installation所述。我搜索了这些错误消息,但没有找到任何有用的信息。

运行RAILS_ENV = production rake db:migrate时,我收到以下错误消息:

SUDO

webistrano username$ sudo RAILS_ENV=production rake db:migrate 
/Users/username/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:900:in `report_activate_error': Could not find RubyGem rake (>= 0) (Gem::LoadError)
    from /Users/username/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:248:in `activate'
    from /Users/username/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:1276:in `gem'
    from /Users/u sername/.rvm/gems/ruby-1.9.2-p180/bin/rake:18:in `<main>'

没有SUDO

webistrano username$ RAILS_ENV=production rake db:migrate 
rake/rdoctask is deprecated.  Use rdoc/task instead (in RDoc 2.4.2+)
rake aborted!
uninitialized constant MysqlCompat::MysqlRes

Tasks: TOP => db:migrate
(See full trace by running task with --trace)

谢谢。

1 个答案:

答案 0 :(得分:0)

这里已经多次询问并解决了MysqlRes问题。简短的回答是你需要reinstall the gem with custom settings

相关问题