Little problem with ant install task

  • Thread starter Werner Butscher
  • Start date
W

Werner Butscher

Hi,

I found out that i can use ant for installing my web application.
great, I have copied some code from an example and added the taskdef's
to the top of my build.xml.
Then I copied the catalina-ant.jar into my java classpath.

But when I run it, I get :
"A class needed by class org.apache.catalina.ant.InstallTask cannot be
found: org/apache/tools/ant/Task"

I looked into the catalina-ant.jar and could not find a Task class
indeed, but then, where is it...?

Taskdef:
<taskdef name="install"
classname="org.apache.catalina.ant.InstallTask" />
<taskdef name="remove"
classname="org.apache.catalina.ant.RemoveTask" />
Target:
<target name="install" depends="war" description="Install servlet
on tomcat.kochan.de">
<install url="${tomcat.url}" username="${manager.username}"
password="${manager.password}" path="${app.path}"
war="jar:file:/${war.dir}/${project}.war!/" />
<sleep seconds="2"/>
</target>

Thanks for help!
Werner
 
A

Antoine Levy-Lambert

Hello Werner,

org.apache.tools.ant.Task is probably installed somewhere in tomcat.
Otherwise, you need to download ant from ant.apache.org.
The Task class is in the ant.jar file.

Hopes this helps.

If you have more problems, mail user at ant dot apache dot org.

Cheers,

Antoine


(e-mail address removed) (Werner Butscher) wrote in message
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top