Refering to: #35 and https://github.com/carlhuda/bundler/blob/1-0-stable/lib/bundler/capistrano.rb
When the Gemfile has been updated the rake task to precompile the assets will fail because bundle:install has not been run yet. I suggest to change after 'deploy:update_code', 'deploy:assets:precompile' to before "deploy:symlink", "deploy:assets:precompile".
after 'deploy:update_code', 'deploy:assets:precompile'
before "deploy:symlink", "deploy:assets:precompile"
There's an easy workaround for now, just add before "deploy:assets:precompile", "bundle:install" to your deploy.rb
before "deploy:assets:precompile", "bundle:install"
@gucki Can yo share your Capfile, deploy.rb (obfuscating anything sensitive), and Bundler version?
@cgriego I could post my configuration files, but they are pretty much standart. bundler is at 1.0.15. Looking at the sources I mentioned you can easily see why bundle:install is called after deploy:assets:precompile.
In bundler capistrano recipe: after "deploy:finalize_update", "bundle:install"
In capistrano assets: before 'deploy:finalize_update', 'deploy:assets:symlink'
after "deploy:finalize_update", "bundle:install"
before 'deploy:finalize_update', 'deploy:assets:symlink'
If you still need my configs, please let me know and I'll post them asap.
@gucki I need to see them. Specifically how you're loading the deploy, deploy/assets, and bundler recipes.
@cgriego: Ok, here they are :)
I'm sorry I haven't responded back. Past couple of days got away from me, and then the issue turned out to be more subtle than I expected. Just wanted to let you know I haven't forgotten you.
@cgriego Thanks for keeping me updated, very nice :)
Bundle install isn't the only issue. I have a custom task I was running after deploy:update_code to write my production database.yml files. If this doesn't go before the asset precompile, I get a failure because rake isn't loading right. There are other post-code-update things people might want to do as well that may affect how it runs. I ended up moving it to before deploy:finalize_update, but it feels wrong and brittle to have to jigger things around like that.
Would before deploy:symlink be so bad? I can't think of anything else that would depend on this update except for the running app, so it seems like a good place to make it happen without being affected by anything else.
@cgriego Any news? :) What are the problems you are facing?
Okay, there are two options here.
Seems to be working fine for me now using bundler 1.0.18, so I'm closing this issue. Thanks!