tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emerson Cargnin - MSA" <emers...@sicredi.com.br>
Subject Re: Where is catalina-ant.jar file?
Date Fri, 17 May 2002 16:56:32 GMT
i'm using reload task of catalina-ant.jar and doing the context deletion and
unwar  through ant tasks (before reloading, of course). Beyond that, i use
Ant 1.5b new element Condition-http so I can see if tomcat is started,
otherwise you will get a error when trying to reload tomcat.

here goes the task:

   <!-- Deploy para tomcat -->
   <target name="testTomcat" depends="deployjboss" >
     <condition property="tomcat.started">
   <!-- http url="${tomcat.url}"/ -->
  <socket server="localhost" port="8000"/>
   </condition>
   <echo message="testando se tomcat esta no ar"/>
   </target>

   <target name="deploytomcat" depends="deployjboss" >
   <delete includeEmptyDirs="true"  failonerror="false">
       <fileset dir="${tomcat.deploy.dir}/${tomcat.path}" />
      </delete>
   <echo message="Undeploy tomcat app"/>
   <unwar src="${dist.dir}/${name}-web.war"
dest="${tomcat.deploy.dir}/${tomcat.path}" />
   <echo message="descompactou app web"/>
   </target>

   <target name="reloadtomcat" depends="deploytomcat,testTomcat"
if="tomcat.started" >
   <echo message="tomcat no ar : recarregando app"/>
   <reload  url="${tomcat.url}" username="${tomcat.username}"
password="${tomcat.password}"
            path="${tomcat.path}"/>
   <echo message="web app recarregando"/>
   </target>


--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message