You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by dh...@lexmark.com on 2006/06/27 17:06:23 UTC
Problem referencing webapp with different context name
Hi,
We install a webapp under tomcat\webapps\mywebapp by exploding the
appropriately named war file.
However, we need users to be able to reference it by typing in
http://myserver/differentName.
I tried adding a mywebapp.xml file under C:\jakarta-tomcat-5.5.12
\conf\Catalina\localhost with the context definition:
<context name="/differentName" path="/mywebapp"/>
but I get an error
"WARNING: A docBase C:\jakarta-tomcat-5.5.12\webapps\mywebapp inside
the host appBase has been specified, and will be ignored"
I *think* I can get around this by placing the webapp outside of the
\webapps folder, but then I lose the ability to explode the war.
It seems to work ok if I place the context definition in server.xml, but
that's not recommended by the docs.
What am I missing - surely this is possible?
cheers,
David
---------------------------------------------------------------------
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
Re: Problem referencing webapp with different context name
Posted by Pid <p...@pidster.com>.
dhay@lexmark.com wrote:
> Hi,
>
> We install a webapp under tomcat\webapps\mywebapp by exploding the
> appropriately named war file.
>
> However, we need users to be able to reference it by typing in
> http://myserver/differentName.
>
> I tried adding a mywebapp.xml file under C:\jakarta-tomcat-5.5.12
> \conf\Catalina\localhost with the context definition:
>
> <context name="/differentName" path="/mywebapp"/>
>
> but I get an error
>
> "WARNING: A docBase C:\jakarta-tomcat-5.5.12\webapps\mywebapp inside
> the host appBase has been specified, and will be ignored"
>
> I *think* I can get around this by placing the webapp outside of the
> \webapps folder, but then I lose the ability to explode the war.
>
> It seems to work ok if I place the context definition in server.xml, but
> that's not recommended by the docs.
>
> What am I missing - surely this is possible?
Rename the mywebapp.xml file to differentName.xml, and re-read the
admittedly unclear docs about the path attribute at:
http://tomcat.apache.org/tomcat-5.5-doc/config/context.html
> cheers,
>
> David
>
>
> ---------------------------------------------------------------------
> 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
>
>
>
---------------------------------------------------------------------
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