LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   How to deploy a web application in tomcat using ant? (https://www.linuxquestions.org/questions/ubuntu-63/how-to-deploy-a-web-application-in-tomcat-using-ant-758860/)

devill 10-01-2009 01:46 AM

How to deploy a web application in tomcat using ant?
 
How to deploy a web application in tomcat using ant?

Thunderstorm 10-01-2009 02:15 AM

The easiest way without Ant is to edit the TOMCAT_HOME/conf/server.xml and add something like the following line:

<Context path="/contextpath" docBase="/home/yournamehere/yourwebapp" debug="0" reloadable="true"/>

If you really want to use ant you can do something like:

<target name="deploy-local" depends="webapp">
<property name="tomcat.local" value="c:/jakarta-tomcat-4.0.2" />
<copy todir="${tomcat.local}/webapps/${project}">
<fileset dir="${webapp}" />
</copy>

Remember to set the tomcat.local value in the build.properties if you have Tomcat installed in a non standard location.

eg: tomcat.local=/opt/tomcat

I noticed you opened ~4 topics with the same subject. One will be enough I think. ;)

acid_kewpie 10-01-2009 02:18 AM

Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.


All times are GMT -5. The time now is 12:55 AM.