|
From: | Eric Pailleau |
Subject: | Re: start/stop command and "cd" |
Date: | Wed, 20 Oct 2010 17:33:12 +0200 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.10) Gecko/20100624 Mandriva/3.0.5-0.1mdv2009.1 (2009.1) Thunderbird/3.0.5 |
Le 20/10/2010 16:15, Josh Sharpe a écrit :
Thanks Eric, Rory, So this works... start program = "/bin/bash -c 'cd /some/path; VAR=blah rake ts:start'" Which is 90% of the problem. The other 10% is that rake should really be executed as another user, not root. So I tried this: start program = "/bin/bash -c 'su - some_user -c \'cd /some/path; VAR=blah rake ts:start\''"
Hello, simply do : start program = "/bin/su - user -c 'cd /some/path; VAR=blah rake ts:start'" By logging to a user, you will load the environnement and use its shell recorded in /etc/passwd . Certainly /bin/bash in your case. Regards
[Prev in Thread] | Current Thread | [Next in Thread] |