WebFaction
Community site: login faq

I have a capistrano deploy script that works great except for the restart task. I have it run bin/restart but it never returns control back. The restart does actually work it's just that capistrano doesn't realize the command is finished. I've even run an 'ls' command afterwards "some_path/bin/restart;ls" and have tried returning true "some_path/bin/restart;true" but neither helped. The ls command ran and returned a listing but never 'exited'.

The restart task is below (site contains the rails deployment directories/symbolic links).

set :deploy_to, "/home/<username>/webapps/<application>/site"
namespace :deploy do
  task :restart, :roles => :app, :except => { :no_release => true } do
    run "#{deploy_to}/../bin/restart"
  end
end

Oddly I can run from the command line in a normal ssh session and it works fine - restarts in a couple seconds.

Any ideas?

asked 05 Jun '11, 23:20

aleis
111
accept rate: 0%

Hi,

This seems to be a bug in the net-ssh package as explaine dhere:

https://capistrano.lighthouseapp.com/projects/8716/tickets/79-capistrano-hangs-on-shell-command-for-many-computers-on-ruby-186-p368#ticket-79-48

Can you try upgrading it and see if that helps?

(05 Jun '11, 23:32) neeravk

My net-ssh package is at the latest in rubygems (2.1.4). I'm running ruby 1.8.7p302 through rvm as I wanted roughly the same version as on webfaction (though I'm not running ree). It's pretty late here - will try running a later ruby version tomorrow and see if there is any difference. Thanks for the link.

(06 Jun '11, 00:11) aleis
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×32
×28
×24
×20
×4

question asked: 05 Jun '11, 23:20

question was seen: 3,072 times

last updated: 06 Jun '11, 00:11

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM