I have a similar need. I have a context file with a JNDI resource, and some
env entries. I want this context file to be copied to the
$CATALINA_HOME/conf/Catalina/localhost/ directory do that the users can use
the default JNDI and env values I enter. 

My app exisits within the appbase and I want this context file to be copied
to the $CATALINA_HOME/conf/Catalina/localhost/ directory when my webapp is
deployed.

Mike

-----Original Message-----
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, October 18, 2006 1:28 PM
To: Tomcat Users List
Subject: RE: placing context.xml in META-INF works?

> From: Jason Novotny [mailto:[EMAIL PROTECTED] 
> Subject: placing context.xml in META-INF works?
> 
> I have a context.xml file that looks basically like this:
> 
> <Context path="/portal" debug="0" reloadable="false" 
> crossContext="true"/>

Take out the path attribute - it's not allowed unless the <Context>
element is in server.xml, which is strongly discouraged.

> I was told I could package this in the META-INF directory of 
> my WAR file and it would get automatically deployed in Tomcat
> -- is this correct?

Yes - it must be named context.xml when under META-INF.

> I tried it but didn't see my context file in the 
> $CATALINA_HOME/conf/Catalina/localhost/ directory
> after starting up...

Why do you think you should?  It will only be copied there if the webapp
resides outside of the declared appBase for the <Host>.

 - 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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



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

Reply via email to