[Mongrel] Mongrel_rails restart and sudo

Tom Brice tom at onidle.com
Fri Jun 16 11:56:37 EDT 2006

On 6/16/06 10:47 AM, Tom Brice  wrote:

> On 6/16/06 10:29 AM, Alison Rowland  wrote:
>> two lines, like so:
>> run "cd #{current_path}"
>> sudo "mongrel_rails restart"
> Thanks Alison.
> I though I tried this but I just rechecked.  Problem is capistrano.  When I
> try this the cd executes but doesn't "hold".  This means that my mongrel_rails
> restart command is executed in my home dir (not my RAILS_ROOT).  It doesn't
> find the PID file so it fails.
> Any other ideas?
> Tom

Also just checked doing this at the server (to take capistrano out of the

sudo mongrel_rails restart

Still gives me the failure because the mongrel_rails start command executed
by mongrel_rails restart does not "inherit" sudo privileges.  So same error
trace as my original message.


More information about the Mongrel-users mailing list