tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: Tomcat Manager sees distribution directories as applications
Date Mon, 02 Nov 2009 20:01:05 GMT
Hash: SHA1


On 11/2/2009 2:37 PM, Jonathan Mast wrote:
> By nightmare I meant complexity.  Currently all my webapps are located in a
> single directory, its flat, it only contains webapps (IE. folders with a
> WEB-INF directory).  I have approximately a dozen Hosts defined across 3
> domain names (and every intention of adding more).  Some Hosts have single
> Contexts, but others have dozens of Contexts defined.

This shouldn't be a problem.

> If each Host must
> have it's own unique appBase for the Manager to work correctly

This is not altogether true. If you want to deploy all of your webapps
individually and explicitly using files in
conf/Catalina/[host]/[context].xml, then you can set all the <Host>
appBase's to the same empty directory if you want. It shouldn't be a
problem as long as you don't put anything in there.

But yes, if you want to be entirely safe, it wouldn't be a bad idea to
create an empty appBase directory for each host. This shouldn't
represent too much of a problem to create empty directories, right?

At any rate, it might be a good idea to request an enhancement in Tomcat
to allow an appBase-less <Host> for just this situation.

> then that
> entails a 3 level structure for my webserver's document root:
> /
> --/webapps
> -----/host_<MY_HOST>
> -------/<MY_CONTEXT>

While this is not strictly necessary, it is "recommended technique". It
will save you from having to put lots of
conf/Catalina/[host]/[context].xml files all over the place, too, since
you can simply auto-deploy them.

> Which means reworking the build scripts for each and every webapp.

Changing the target directory for a build script should be trivial. Is
it not in your deployment process?

> If this is the only way to have the manager work correctly, then I
> guess I'll have to do.

None of this really has anything to do with the Manager app itself,
really. You can choose to deploy or not deploy the Manager into each <Host>.

> I just don't understand why the server.xml cannot be interpreted as
> a logical structure.

I'm not sure I understand your statement, here.

> If I can define a "/blahblah" Context on a docBase of "foobar-webapp" (a
> logical or arbitrary mapping) why can't Contexts be understood as belonging
> to certain arbitrary Hosts, regardless of their filepath?

They can, if you use the "conf/Catalina/[host]/[context].xml"-style

- -chris
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla -


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

View raw message