ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antoine Levy-Lambert" <anto...@antbuild.com>
Subject Re: Starting up tomcat via the <exec> task?
Date Mon, 04 Aug 2003 15:25:59 GMT
It would be
<exec executable="java">
    <arg value="-cp"/>
    <arg value="${java.home}/../lib/tools.jar;..."/>
.... all your jvm args, ...
    <arg value="org.apache.catalina.startup.Bootstrap"/>
    <arg value="start"/>
</exec>

note that in ant1.6alpha there is a spawn attribute for both exec and java.
I have not tested starting tomcat directly like this as a java process, but
it should work.
Why do you want to use <exec/> instead of <java/> to start tomcat if you are
not calling a wrapper shellscript ?

Cheers,

Antoine



----- Original Message -----
From: <billy.bacon@thirty3.net>
To: <user@ant.apache.org>
Sent: Friday, August 01, 2003 10:32 PM
Subject: Starting up tomcat via the <exec> task?


> I know there's a specific task <java> for starting up
> tomcat but how would I start up tomcat through the
> <exec> task... I have the following in my build.xml
> file...
>
> <java
> classname="org.apache.catalina.startup.Bootstrap"
> fork="true">
> <classpath>
> <pathelement
> location="${java.home}/../lib/tools.jar"/>
> <pathelement
> location="${catalina.home}/bin/bootstrap.jar"/>
> </classpath>
> <jvmarg value="-Dvoyager=1"/>
> <jvmarg
> value="-Djava.endorsed.dirs=${tc.endorsed.dirs}"/>
> <jvmarg value="-Dcatalina.home=${catalina.home}"/>
> <jvmarg value="-Dcatalina.base=${catalina.base}"/>
> <jvmarg
> value="-Djava.io.tmpdir=${catalina.tempdir}"/>
> <jvmarg value="-Dfile.encoding=UTF-8"/>
> <jvmarg value="-Xmx${catalina.heapsize}m"/>
> <jvmarg value="-Xdebug"/>
> <jvmarg value="-Xnoagent"/>
> <jvmarg value="-Xrunjdwp:transport=${debug.args}"/>
> <arg value="start"/>
> </java>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message