tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Barrett <m...@daboyz.org>
Subject Re: Doc on ant deploy
Date Tue, 29 Apr 2003 20:07:10 GMT
I think he means the deploy target that comes with the catalina hooks for ant.  Maybe my lingo
is off, but I'm new to java/ant :)  Anyways, I had to figure out how to use deploy myself,
and here is what I came up with:

    <target name="deploy" description="Deploy App">
        <deploy url="${url}" username="${username}" password="${password}" 
            path="/appPath" 
            war="file:/full/path/to/app.war"/>
    </target>

Hope that helps.

Note I've been having problems with both deploy and install.  Instead of deploying to my servers
'appbase' it installs it in the work/Standalone/localhost directory, and some of my property
files are missing.  I've asked about it on this list but haven't heard back yet.  Anyways,
if you run into the same thing, I'd be curious to hear about it.

On Tue, Apr 29, 2003 at 12:14:16PM -0500, Arturo Vazquez wrote:
> On Tue, 2003-04-29 at 07:43, Jeffrey Cummings wrote:
> > Where can I find complete documentation on ant ?deploy? task?
> > 
> I can't find a deploy task in the estandar/with optional tasks
> distribution of ant so my guess is you are trying to deploy  webapp
> using ant but don't know how...
> am I right???
> well in that case maybe this piece of my build.xml can help you
>  <!-- ==================== Deploy Target
> =================================== -->
>   
>   <!--
>   
>     The "deploy" target copies the contents of the build directory into
> a
>     location required by our servlet container, and picks up any
> external
>     dependencies along the way.  AFter restarting the servlet container,
> you
>     can now test your web application.
>   
>   -->
>   
>     <target name="deploy" depends="package"
>      description="Deploy application to servlet container">
> 
>       <!-- create the webapp image in the build directory -->
>       <mkdir dir="${prepare.home}"/>
> 
>       <!-- Copy the contents of the build directory -->
> 
>       <mkdir dir="${prepare.home}"/>
>       <mkdir dir="${prepare.conf}"/>
>       <copy todir="${prepare.conf}">
>          <fileset dir="${webapp.conf}"/>
>       </copy>
>       <mkdir dir="${prepare.css}"/>
>       <copy todir="${prepare.css}">
>          <fileset dir="${webapp.css}"/>
>       </copy>
>       <mkdir dir="${prepare.img}"/>
>       <copy todir="${prepare.img}">
>          <fileset dir="${webapp.img}"/>
>       </copy>
>       <mkdir dir="${prepare.dtd}"/>
>       <copy todir="${prepare.dtd}">
>          <fileset dir="${webapp.dtd}"/>
>       </copy>
>       <mkdir dir="${prepare.js}"/>
>       <copy todir="${prepare.js}">
>          <fileset dir="${webapp.js}"/>
>       </copy>
>       <mkdir dir="${prepare.lib}"/>
>       <!-- all the libraries we use -->
>       <copy file="${postgres.jar}"        todir="${prepare.lib}" />
>       <copy file="${log4j.jar}"           todir="${prepare.lib}" />
> 
>       <!-- to use in production -->
> <!--
>       <copy    todir="${deploy.conf}/lib">
>         <fileset dir="${build.dir}/${name}.jar">
>       </copy>
> -->
>       <!-- while developing  -->
>       <mkdir dir="${prepare.classes}"/>
>       <copy todir="${prepare.classes}">
>         <fileset dir="${build.dir}/classes"/>
>       </copy>
> 
>     <!-- Copy the contents of the prepare directory -->
>     <mkdir     dir="${deploy.home}"/>
>     <copy    todir="${deploy.home}">
>       <fileset dir="${prepare.home}"/>
>     </copy>
>     <!-- this libraries go to the endorsed dir -->
>     <copy file="${xerces.jar}" todir="${deploy.endorsed}" />
>     <copy file="${xalan.jar}"  todir="${deploy.endorsed}" />
> 
>     </target>
> 
> 
> and the relevant properties are:
>     <property name="name" value="myServlets"/>
>     <property name="webapp.name"       value="${name}"/>
>     <property name="catalina.home"     value="/var/tomcat4/"/> 
>     <property name="catalina.lib"      value="${catalina.home}/lib"/> 
>     <property name="deploy.home"      
> value="${catalina.home}/webapps/${webapp.name}"/>
>     <property name="deploy.endorsed"  
> value="${catalina.home}/common/endorsed"/>
>     <property name="prepare.home"      value="${build.dir}/prepare"/>
>     <property name="prepare.conf"      value="${prepare.home}/WEB-INF"/>
>     <property name="prepare.css"       value="${prepare.home}/css"/>
>     <property name="prepare.img"       value="${prepare.home}/img"/>
>     <property name="prepare.dtd"       value="${prepare.home}/dtd"/>
>     <property name="prepare.js"        value="${prepare.home}/js"/>
>     <property name="prepare.lib"       value="${prepare.conf}/lib"/>
>     <property name="prepare.classes"   value="${prepare.conf}/classes"/>
>     <property name="webapp.conf"       value="./web/WEB-INF"/>
>     <property name="webapp.css"        value="./src/css"/>
>     <property name="webapp.img"        value="./src/img"/>
>     <property name="webapp.dtd"        value="./src/dtd"/>
>     <property name="webapp.js"         value="./src/js"/>
> 
> hope it helps ...
> 					VAZ
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 

-- 
     ________________________________________________________________________
                Mike Barrett | "I used to read, now I go to raves."
             mike@daboyz.org | -- Random MUNI Rider, speaking
              www.daboyz.org |    to my friend Allison.
     ------------------------+-----------------------------------------------

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


Mime
View raw message