Java Mailing List Archive

http://www.ant-tasks.com/

Apache Ant Archive

» Ant Users List
» Ant Developers List
Problem with SSHEXEC and nohup

Problem with SSHEXEC and nohup

2005-05-13       - By Dave Bartmess
Reply:     1     2     3  

I'm trying to do a four-task parallel call, using sshexec to call the
remote builds. Each build is a replica of the calling build, just on a
different platform.

The build script portion is below.

The problem is, when ant executes the sshexec task, despite what I put
in the remotebuild.sh, such as "nohup ... &" (insert command for "...")
or send the command through sshexec as "nohup remotebuild.sh 2>&1
>build.log &", it won't work. It waits for the build command
inside the remotebuild.sh to complete, no matter if the build command
itself is nohup'd, or the sshexec command is nohup'd.

I could use some help. I've tried every alternative I could think of...

Thanks!

*************************************************
(WITH nohup in the ssh'd command)

local build script:
<target name="build-linux">
 <sshexec
     command="nohup ./remotebuild.sh ${product.name} ${build.number}
2&gt;&amp;1 &gt;build.log &amp;"
     username="${Linux.build.user}"
     host="${Linux.build.host}"
     keyfile="${env.HOME}/.ssh/id_dsa"
     trust="true"/>
 </target>

remote build script:
cvs co -A $PRODUCT
./build installer.xml -Dbuild.number=$2 installer
exit

*************************************************
(WITH nohup in the remote command script)

local build script:
<target name="build-linux">
 <sshexec
     command="./remotebuild.sh ${product.name} ${build.number}"
     username="${Linux.build.user}"
     host="${Linux.build.host}"
     keyfile="${env.HOME}/.ssh/id_dsa"
     trust="true"/>
 </target>

remote build script:
cvs co -A $PRODUCT
nohup ./build installer.xml -Dbuild.number=$2 installer 2>&1 >build.log
&
exit

*************************************************

--
David A. Bartmess
Sr. Software Configuration Manager / Sr. Software Developer
eDingo Enterprises
http://edingo.net


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)


©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.