Thanks,
just a question here.

Set the appBase attributes for all your Host elements to different paths
and make sure that not one is contained in another. For example, if
you've got two hosts, "localhost" and "www.test.com", you could
configure them like that:
<Host name="localhost" appBase="webapps/localhost" [...]
and
<Host name="www.test.com" appBase"webapps/test" [...] 

The question:
If I have a subdomain, demo.test.com, should I define a new Host?
<Host name="demo.test.com" appBase"webapps/demo.test"

The name after webapps/, which is demo.test, can it be named anyhow?
for example webapps/mydemotestwebapp



Markus Schönhaber-10 wrote:
> 
> jerrycat wrote:
> 
>> Here is the context.xml
>> <Context path="" docBase="C://Program Files//Apache Software
>> Foundation//Tomcat 5.5//webapps//test"> 
> [...]
>> </Context>
> 
> Please read the docs:
> http://tomcat.apache.org/tomcat-5.5-doc/config/context.html
> Especially the last paragraphs in the descriptions of the docBase and 
> the path attributes.
> You have not mentioned how you are going to deploy your webapp. 
> Therefore I'll simply assume you want to autodeploy a war file or an 
> exploded war file.
> In this case, remove the path and docBase attributes from the Context 
> element.
> 
>> and here is the Host element in the conf/server.xml
>> <Host name="www.test.com" deployOnStartup="true" debug="0"
>> appBase="webapps"
> 
> Set the appBase attributes for all your Host elements to different paths 
> and make sure that not one is contained in another. For example, if 
> you've got two hosts, "localhost" and "www.test.com", you could 
> configure them like that:
> <Host name="localhost" appBase="webapps/localhost" [...]
> and
> <Host name="www.test.com" appBase"webapps/test" [...]
> 
> If you want a webapp to be accessible via www.test.com, drop the 
> corresponding war file into $CATALINA_BASE/webapps/test.
> If a webapp shall be the default Context for a given Host, name it 
> "ROOT" and deploy it to the Host's appBase.
> 
>> unpackWARs="true" autoDeploy="true" xmlValidation="false"
>> xmlNamespaceAware="false"> 
> [...]
>> </Host>
> 
> Regards
>    mks
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Tomcat-5.5-context.xml%2C-how-to-configure-the-Host-element-tp19152267p19161308.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
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