tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Thomas <>
Subject Re: How to configure a web app
Date Thu, 10 Jun 2010 20:06:22 GMT
On 10/06/2010 20:52, André Warnier wrote:
> Does there exist *any* way to put the actual values "value1", "value2",
> etc.. in some place *outside* the web.xml file, and *outside* the war
> that would be created for this application, and still allow the
> application, on startup, to read the values of these parameters "from
> web.xml" ?


> And if yes, is this Tomcat-specific, or servlet-engine-generic ?

Tomcat specific.

Any xml configuration file processed by the digester (server.xml, global
and application context.xml, global and application web,xml) can use ant
style property replacement.

Use ${myproperty} in the xml file and in
$CATALINA_BASE/conf/ use:

There are some restrictions on exactly how you can use this. It
certainly works for attribute values, it may work for
<value>${...}</value> as well - I haven't tested it or checked the code
to see exactrly how it works.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message