Use Ant to make you programs (5)

xiaoxiao2021-03-06  108

[Home, Previous, Next]

5 cooperation with Tomcat

Summary: Introduction Build_Tomcat.xml, Tomcat.xml

Now introduce how to cooperate with Tomcat. Java's program is involved in web, and it is still very convenient to use Tomcat when testing.

BUILD_TOMCAT.XML in Work / Common / Tomcat.xml is a profile that works with Tomcat, which is simple.

Build_tomcat.xml

Copyright 2004 CAMRY.WU@gmail.com

This Program Is Free Software; You Can Redistribute IT and / or Modify

It Under The Terms of The GNU General Public License As Published by

The Free Software Foundation; Either Version 2 of the license, OR

ANY LATER VERSION.

This Program is Distributed in the Hope That IT Will Be Useful,

But without Any Warranty; WITHOUT EVEN THE IMPLIED WARRANTY OF

Merchantability or fitness for a particular purpose. See the

GNU General Public License for more details.

You Should Have Received A Copy of The GNU General Public License

Along with this program; if not, Write to the Free Software

Foundation, inc.

->

Semanticattributes = "true" keEProot = "false" />

Depends = "compile" Description = "deploy application">

Depends = "jar" description = "Deploy Application As a War File">

UserName = "$ {tomcat.manager.username}"

Password = "$ {Tomcat.Manager.password}"

PATH = "/ $ {component.name}"

WAR = "$ {component.name} .war" />

UserName = "$ {tomcat.manager.username}"

Password = "$ {Tomcat.Manager.password}"

PATH = "/ $ {component.name}" />

UserName = "$ {tomcat.manager.username}"

Password = "$ {Tomcat.Manager.password}"

PATH = "/ $ {component.name}" />

UserName = "$ {tomcat.manager.username}"

Password = "$ {Tomcat.Manager.password}"

PATH = "/ $ {component.name}" />

UserName = "$ {tomcat.manager.username}"

Password = "$ {Tomcat.Manager.password}" />

Tomcat.xml

Copyright 2004 CAMRY.WU@gmail.com

Ant Build Environment for Tomcat

->

http://127.0.0.1:8080/Manager

CAMRY

CAMRY

War

$ {Tomcat.home} / webapps

When using it, pay attention to establish a WAR directory in WORK / engineering directory / under the WORK / engineering directory, WAR directory structure: WORK / project

| - Web-INF / | - Classes / # Place Class files

| - LIB / # 放 放 需要 需要 j j

| - Web.xml # web configuration file

With these configurations, just start Tomcat when working with Tomcat, then don't have to take Tomcat, just call Ant Deploy, Ant Stop, Ant Start and other tasks.

[Home, Previous, Next]

转载请注明原文地址:https://www.9cbs.com/read-103097.html

New Post(0)