We were unable to load Disqus. If you are a moderator please see our troubleshooting guide.

Philip Hallstrom • 11 years ago

There is a fork of whenever that supports Capistrano 3. Full disclosure: I wrote it.

https://github.com/phallstr...
https://github.com/phallstr...

https://github.com/javan/wh...

darkofabijan • 11 years ago

It works great for us. Thanks Philip!

Dmitry Cross • 11 years ago

Big thanks to you. I faced difficulties in due to migrate to the new version and spent a lot of time configuring deploy.rb. This article helped me.

Robert Reiz • 11 years ago

Since I moved to Capistrano 3 the assets:precompile doesn't get executed. Any idea why it does not precompile the assets?

darkofabijan • 11 years ago

Hi Robert,

Do you have following line in your Capfile?

require "capistrano/rails/assets"

Robert Reiz • 11 years ago

Yes. But that didn't worked. I exchanged it with "require 'capistrano/rails'". And I added explicitly a task ":precompile" to my deploy.rb. Not it works fine. But I still don't understand why it doesn't work out of the box.

method • 11 years ago

I bet your problem was the same as mine, that I hadn't added the :web role to the server I was deploying to. See the assets_roles setting on https://github.com/capistra...

Robert Reiz • 11 years ago

Yes. That was the problem. But with the current version of capistrano-rails its fixed now.

TheHungryCoder • 10 years ago

Thanks a lot! I solved my similar problem by adding appropriate assets roles.

Sean Horan • 11 years ago

Capistrano3 doesn't deploy:restart automatically. You have to add after 'deploy:publishing', 'deploy:restart', likely within the web role.

Ben Dixon • 11 years ago

For anyone who's confused with why this is working for some and not for others it's because deploy:restart was called automatically in the 3.0 release but removed in 3.1

Hung • 11 years ago

I have Error when run cap deploy:

NameError: undefined local variable or method `production' for main:Object

classpath:/config/deploy:1:in `(root)'

/srv/webapps/atan_scrum/Capfile:1:in `(root)'

/srv/webapps/atan_scrum/Capfile:6:in `(root)'

/opt/torquebox/current/jruby/bin/cap:23:in `(root)'

(See full trace by running task with --trace)

Please help me.
Thanks so much.

Andreas Wenk • 11 years ago

Thanks for this post. One thing I would like to mention. Afaik, there is no need to run

after :finishing, "deploy:cleanup"

because it is already in the flow when you rund cap [ENV] deploy. See http://capistranorb.com/doc... for further info.

UPDATE: sry - this is only true when using Rails. Please see the link above.

Amit Patel • 9 years ago

Unable to deploy with private github repo. I am getting following error:

DEBUG [ea32bf2c] ERROR: Repository not found.
DEBUG [ea32bf2c] fatal: Could not read from remote repository.

Detailed question is posted http://stackoverflow.com/qu...