tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Caldarale, Charles R" <Chuck.Caldar...@unisys.com>
Subject RE: Manager deploy uploaded war - doesn't use the /WEB-INF/context.xml
Date Wed, 15 Nov 2006 22:08:33 GMT
> From: Michael Hencin [mailto:michael.hencin@edm-concepts.com] 
> Subject: RE: Manager deploy uploaded war - doesn't use the 
> /WEB-INF/context.xml
> 
> I know I can leave the path out of my META-INF/context.xml file,

Not just can, but *must*.  The same applies to the docBase attribute -
it's only pertinent when your <Context> element is in some place other
than META-INF/context.xml.  The presence of inappropriate attributes may
lead to inappropriate behavior.

> In my original war file I have a context file with;
> 
> <Context crossContext="true" docBase="mywebapp" path="/mywebapp"
> privileged="true" workDir="work\Catalina\localhost\mywebapp">

Both the docBase and path attributes should be removed.  Also, you don't
really need workDir, since Tomcat will provide one for you the value of
which you can retrieve from the ServletContext.

> Is there some way I can "varibalize" the end of those to 
> match the war file name?

Mostly just by removing them.

> So what I would like is have a context file that will 
> put the proper entires into the context element, based
> on the war file name.

If you just remove the unnecessary attributes from the <Context>
element, I think you'll have achieved that goal.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

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


Mime
View raw message