Ken Bowen wrote:
> Sorry about that....some kind of sloppiness on my part.
> 
> I've realize the problem must lie in the relationship between my app's
> META-INF/context.xml and what is configured in Tomcat's conf/server.xml.
> IIn the latter,  found there was an old Context entry in the Host element:
> 
> <Host appBase="webapps" name="strong-brain.com" unpackWARs="true"
> autoDeploy="true">
> 
>          <Alias>www.strong-brain.com</Alias>
>          <Alias>216.154.215.173</Alias>
>         <Context path="" docBase="strongbrain" debug="10"
> reloadable="true" cookies="true"/>          <Context path="/manager"
> docBase="/opt/tomcat5/server/webapps/manager" privileged="true" debug="0"/>
>          <Context path="/admin"
> docBase="/opt/tomcat5/server/webapps/admin" privileged="true" debug="0"/>
>          <Logger className="org.apache.catalina.logger.FileLogger"
> prefix="strong-brain.com." suffix=".txt" timestamp="true"/>
>      </Host>
> 
> So what I'm confused about is this:  Exactly what should appear in Host
> and what in META-INF/context.xml    ??
> The "A Word on Contexts" in
> http://tomcat.apache.org/tomcat-5.5-doc/deployer-howto.html doesn't give
> any details.

http://tomcat.apache.org/tomcat-5.5-doc/config/context.html

Context definitions in server.xml are strongly discouraged in recent
releases of Tomcat.  Remove the definition with the empty path
attribute. (We'll address the admin/manager apps later).

DO NOT use the path or docBase attribute in a Context defined outside of
server.xml.  (The path is determined from the WAR or deployed
application directory.)

The default Context for a Host is known as the ROOT Context, this is a
special name and the capitalisation is important.  If you're deploying
your app as the default, you should rename the WAR (or the directory if
it's unpacked/deployed) accordingly.

your/webapps/ROOT.war
your/webapps/ROOT/      << unpacked files

If you want to store the files outside of the tomcat directory, just
alter the appBase attribute of the host.  The following illustrates this:

/my/sites/www.domain.com/webapps/ROOT
/my/sites/www.domain.com/webapps/ROOT/META-INF/context.xml

<Host appBase="/my/sites/www.domain.com/webapps" name="domain.com" ...>


p




> Thanks,
> Ken
> 
> Caldarale, Charles R wrote:
>>> From: Ken Bowen [mailto:[EMAIL PROTECTED] Subject: Weird problem: Two
>>> apparent copies of app started
>>>
>>> strongbrain/WEB-INF/lib/servlet-api.jar
>>>     
>>
>> One obvious error: you must not put the servlet-api.jar inside your
>> webapp - the container supplies that.  Remove it and see if it helps.
>>
>>  - 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]
> 
> 


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