Capistrano error: Sprockets :: FileNotFound: Could not find file 'bootstrap-sprockets'

I am using stone gem "bootstrap-sass"

.

In application.js

:

//= require jquery
//= require jquery_ujs
//= require bootstrap-sprockets
//= require_tree .

      

in application.css.scss

:

@import "bootstrap-sprockets";
@import "bootstrap";

      

On localhost everything works fine, but when I try to deploy the code with Capistrano

I get this error message:

  ...
  * executing "cd -- /home/deployer/apps/app-name/releases/20140805182229 && RAILS_ENV=production RAILS_GROUPS=assets bundle exec rake assets:precompile"
    servers: ["IP"]
    [IP] executing command
 ** [out :: IP] rake aborted!
 ** [out :: IP]
 ** [out :: IP] Sprockets::FileNotFound: couldn't find file 'bootstrap-sprockets'
 ** [out :: IP]
 ** [out :: IP] (in /home/deployer/apps/app-name/releases/20140805182229/app/assets/javascripts/application.js:17)
...

      

The line #17

points here:

// = require bootstrap-sprockets

Why is this and what am I missing here?

+3


source to share


2 answers


I had the same problem, but it seems to have solved the problem by restarting the server after installing the package. Hope this helps.



+4


source


FYI I was able to fix this problem by moving the gem "bootstrap-sass", "~> 3.3.1" to the top of the Gemfile, below the rails line. I don't know why it breaks if it's after refinerycms in the Gemfile.



0


source







All Articles