tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nehal Sangoi" <nehal.san...@patni.com>
Subject deploy fails
Date Wed, 21 Dec 2005 06:41:58 GMT

Hi,

Below is the build.xml and build.properties files i am using for my app
deployments.
Tomcat 5.5.9
Using Tomcat Virtual Instance
Platform - Solaris/Linux
Manager Deployer used

When i do execute the ant command (ant -f abc.xml), it gives me follwoing
output. What could be the possible reason for such error and failure in
deployments?

Response to my query would be highly appreciated.

Thanks & Regards,
Nehal
============================================================================
====================

clean_dest:
   [delete] Deleting directory /appl/abc/deploy/WAR
    [mkdir] Created dir: /appl/abc/deploy/WAR

copy_code_to_dest:
     [copy] Copying 94 files to /appl/abc/deploy/WAR
     [copy] Copying 142 files to /appl/abc/deploy/WAR/WEB-INF/src
     [copy] Copying 6 files to /appl/abc/deploy/WAR/WEB-INF/lib
   [delete] Deleting directory /appl/abc/deploy/CVS
   [delete] Deleting: /appl/abc/deploy/WAR/WEB-INF/lib/expd2util.jar

clean_classes:
    [mkdir] Created dir: /appl/abc/deploy/WAR/WEB-INF/classes

compile_java_code:
    [javac] Compiling 136 source files to
/appl/abc/deploy/WAR/WEB-INF/classes
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] Note: Some input files use unchecked or unsafe operations.
    [javac] Note: Recompile with -Xlint:unchecked for details.
     [copy] Copying 6 files to /appl/bcp/deploy/WAR/WEB-INF/classes

create_war:
      [war] Building war: /appl/abc/deploy/WAR/bcp.war
      [war] Warning: selected war files include a WEB-INF/web.xml which will
be ignored (please use webxml attribute to war task)

deploy:

BUILD FAILED
/appl/abc/deploy/build/bcp.xml:87: java.io.FileNotFoundException:
http://3.160.228.52:7451/manager/deploy?path=%2Fabc&update=true

============================================================================
===================================
BUILD FILE


<project name="abc" basedir="." default="deploy">

   <property file="abc.properties"/>

<!-- Configure the context path for this application -->
          <property name="path"     value="/abc"/>

          <!-- Configure properties to access the Manager application -->
          <property name="url"      value="http://ipaddr:port/manager"/>
          <property name="username" value="manager"/>
          <property name="password" value="manager"/>

          <!-- Configure the custom Ant tasks for the Manager
application -->
          <taskdef name="deploy"
classname="org.apache.catalina.ant.DeployTask"/>
          <taskdef name="list"
classname="org.apache.catalina.ant.ListTask"/>
          <taskdef name="reload"
classname="org.apache.catalina.ant.ReloadTask"/>
          <taskdef name="resources"
classname="org.apache.catalina.ant.ResourcesTask"/>
          <taskdef name="roles"
classname="org.apache.catalina.ant.RolesTask"/>
          <taskdef name="start"
classname="org.apache.catalina.ant.StartTask"/>
          <taskdef name="stop"
classname="org.apache.catalina.ant.StopTask"/>
          <taskdef name="undeploy"
classname="org.apache.catalina.ant.UndeployTask"/>

   <path id="lib.path">
           <fileset dir="${java.lib.dir}">
                  <include name="**/*.jar"/>
           </fileset>
           <fileset dir="${common.lib.dir}">
                  <include name="**/*.jar"/>
           </fileset>
        </path>

        <target name="cvs_checkout">
                <delete dir="${cvs.dir}"/>
                <cvs  cvsroot="${cvs.root}"  package="${cvs.module}"
tag="${cvs.tag}"  dest="${cvs.dir}"/>
   </target>

        <target name="clean_dest">
            <delete dir="${war.dir}" failonerror="false"/>
                <mkdir dir="${war.dir}"/>
        </target>

        <target name="copy_code_to_dest" depends="cvs_checkout,clean_dest">
                <copy todir="${war.dir}">
                        <fileset dir="${cvs.dir}/${cvs.module}/appserver">
                                <include name="**/*"/>
                        </fileset>
                </copy>
                <copy todir="${war.dir}/WEB-INF/src">
                        <fileset dir="${cvs.dir}/${cvs.module}/src">
                                <include name="**/*"/>
                        </fileset>
                </copy>
                <copy todir="${war.dir}/WEB-INF/lib">
                        <fileset dir="${cvs.dir}/${cvs.module}/lib">
                                <include name="**/*"/>
                        </fileset>
                </copy>
                <delete dir="${cvs.dir}" />
                <delete file="${war.dir}/WEB-INF/lib/expd2util.jar" />
                <delete file="${war.dir}/WEB-INF/lib/ibmmq.jar" />
                <delete file="$(war.dir)/WEB-INF/lib/jdom.jar" />
        </target>

        <target name="clean_classes" depends="copy_code_to_dest">
                <delete dir="${java.classes.dir}" failonerror="false"/>
                <mkdir dir="${java.classes.dir}"/>
        </target>

        <target name="compile_java_code" depends="clean_classes">
                <javac srcdir="${java.src.dir}"
destdir="${java.classes.dir}">
                        <classpath refid="lib.path" />
                </javac>
                <!-- Copy non java resourece property files...xml files
etc -->
                <copy todir="${java.classes.dir}">
                        <fileset dir="${java.src.dir}">
                              <include name="**/*.*"/>
                              <exclude name="**/*.java"/>
                        </fileset>
                </copy>
        </target>

        <target name="create_war" depends="compile_java_code">
                <war destfile="${war.dir}/${war.name}" basedir="${war.dir}"
duplicate="fail" webxml="${war.dir}/WEB-INF/web.xml" />
        </target>

        <target name="deploy" description="Install web application"
depends="create_war">
                <deploy url="${url}" username="${username}"
password="${password}" path="${path}" war="${war.dir}/abc.war" update="t
rue"/>
        </target>

        <target name="reload" description="Reload web application"
depends="create_war">
                <reload  url="${url}" username="${username}"
password="${password}" path="${path}"/>
--More--</target>

        <target name="undeploy" description="Remove web application">
                <undeploy url="${url}" username="${username}"
password="${password}" path="${path}"/>
        </target>

</project>


=====================================================
PROPERTIES FILE


project.name=abc

# java properties
java.src.dir=/appl/abc/deploy/WAR/WEB-INF/src
java.lib.dir=/appl/abc/deploy/WAR/WEB-INF/lib
java.classes.dir=/appl/bcp/deploy/WAR/WEB-INF/classes

#destination properties
war.dir=/appl/abc/deploy/WAR
source.dir=/appl/abc/deploy/CVS/tomcat
war.name=abc.war

#cvs properties
cvs.root=:pserver:uid:pwd@cvs-server:cvs-path
cvs.module=abc/tomcat
cvs.tag=
cvs.dir=/appl/abc/deploy/CVS

#tomcat properties
common.lib.dir=/appl/abc/shared/lib


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


Mime
View raw message