【问题标题】:Rake aborting on Rails app Ubuntu在 Rails 应用程序 Ubuntu 上 Rake 中止
【发布时间】:2016-01-27 22:03:06
【问题描述】:

运行$rake时出现以下错误:

$ rake
rake aborted!
LoadError: cannot load such file -- redcarpet.so
/var/www/my_app/code/vendor/bundle/ruby/2.2.0/gems/redcarpet-3.2.3/lib/redcarpet.rb:1:in `require'
/var/www/my_app/code/vendor/bundle/ruby/2.2.0/gems/redcarpet-3.2.3/lib/redcarpet.rb:1:in `<top (required)>'
/var/www/my_app/code/config/application.rb:7:in `<top (required)>'
/var/www/my_app/code/Rakefile:4:in `<top (required)>'
(See full trace by running task with --trace)

Ruby -v:2.2.3
rbenv 本地/全局:2.2.3

Rails -v:4.2.4

我还尝试使用以下命令重新安装 redcarpet gem:

sudo gem install redcarpet 
Fetching: redcarpet-3.3.4.gem (100%)
Building native extensions.  This could take a while...
Successfully installed redcarpet-3.3.4
1 gem installed 

运行良好。关于导致此中止的任何想法?

【问题讨论】:

  • 我猜你可以尝试在没有sudo 的情况下安装gem。我过去遇到过问题;)
  • 会不会是因为您的 ruby​​ 版本是 2.2.3,而 rake 正在寻找 ruby​​ 2.2.0 下的 gem?
  • 如何才能在正确的 ruby​​ 版本中看到它? @MarceloRisoli
  • 我也尝试过不使用 sudo,但也没有用。 @RafaelGoulart

标签: ruby-on-rails ubuntu rake passenger


【解决方案1】:

在本地进行了捆绑安装,再次将其推送到 git,然后进行了上限生产部署。由于某种原因,这似乎解决了它。现在继续讨论我遇到的所有数据库错误。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-11-10
    • 2012-01-19
    • 1970-01-01
    • 2015-10-08
    • 1970-01-01
    • 1970-01-01
    • 2017-04-12
    • 1970-01-01
    相关资源
    最近更新 更多