Hey Jeff, nohup is exactly what I was looking for. I used it before, but I couldn't remember the name of the function.
Thank you for taking the time to clarify how local and & works i really appreciate it. Taras On Fri, Sep 18, 2009 at 9:17 PM, Jeff Forcier <j...@bitprophet.org> wrote: > Hi Taras, > > Using '&' isn't really daemonizing -- it's simply putting the process > into the background of the invoking shell session. This is why local() > never returns: because the shell it creates is still waiting for the > process to finish. > > Instead, you may want to try using 'nohup' or 'screen', which IIRC can > truly detach from the spawning shell, and will then return control to > you. > > Also note that local() is simply a wrapper around the 'subprocess' > module (albeit one that honors Fabric's context managers like cd()) so > you can always use subprocess directly, or other Python modules > dealing with processes, such as 'multiprocessing' or 'os'. > > Best, > Jeff > > On Fri, Sep 18, 2009 at 7:11 PM, Taras Mankovski <tar...@gmail.com> wrote: > > Hey Guys, > > I'm trying to start google app engine's dev_runserver as a daemon. > > So I'm trying to do > > pid = local('./bin/dev_appserver --port=%s beecoop.com & '%(env.port)) > > But when it gets to this line, it just sits there and waits. > > If I run this command in bash I get > > ./bin/dev_appserver --port=10500 beecoop.com & > > [1] 17095 > > Can you please explain why it does this? and what how would I get it > > daemonize and move on? > > Thank you, > > Taras > > _______________________________________________ > > Fab-user mailing list > > Fab-user@nongnu.org > > http://lists.nongnu.org/mailman/listinfo/fab-user > > > > >
_______________________________________________ Fab-user mailing list Fab-user@nongnu.org http://lists.nongnu.org/mailman/listinfo/fab-user