RE: getting Tomcat 5.0 to serve static content

2004-07-09 Thread David . Pawson
 

-Original Message-
From: Matthew Hixson 
I'm using Tomcat 5.0.26 with JBoss 3.2.4.  I'm attempting 
to upgrade from Tomcat 4.1.something that was included with 
JBoss 3.2.3.  I cannot figure out how to configure a 
context so that Tomcat will serve files from a specific 
directory.  The directory contains images and should be 
accessible outside of any specific webapp.  The files are 
stored in /usr/local/watermarks and the URLs to them need 
to look like http://mymachine.com/watermarks/bar.jpg.
   Context path=/watermarks docBase=/usr/local/watermarks/
   I've read all the docs I could find on the Apache Tomcat 
site and used Google to find examples and I cannot find 
anything that tells me how to do this.  In the previous 
version of Tomcat I had put the above Context element 
into 
/usr/local/jboss/server/default/deploy/jbossweb-tomcat41.sar
/META-INF/
jboss-service.xml.  But in Tomcat 5.0 it looks like that 
has moved to jbossweb-tomcat50.sar/server.xml. 

If you read the docs enough times it suggests that the Context element
should be an anyName.xml, in {catalina.home}/conf/host/

Where it hides, just the Context element in an xml file per app.
(I found it useful to name the file after the app)

HTH DaveP

** snip here **


-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: getting Tomcat 5.0 to serve static content

2004-07-09 Thread Dennis Dai
I'm not familiar with JBoss stuff but I think to make a context work, 
you'll need the WEB-INF dir and the associated web.xml ...

On 7/8/2004 10:23 PM, Matthew Hixson wrote:
I'm using Tomcat 5.0.26 with JBoss 3.2.4.  I'm attempting to upgrade  
from Tomcat 4.1.something that was included with JBoss 3.2.3.  I cannot  
figure out how to configure a context so that Tomcat will serve files  
from a specific directory.  The directory contains images and should be  
accessible outside of any specific webapp.  The files are stored in  
/usr/local/watermarks and the URLs to them need to look like  
http://mymachine.com/watermarks/bar.jpg.
   Context path=/watermarks docBase=/usr/local/watermarks/
   I've read all the docs I could find on the Apache Tomcat site and  
used Google to find examples and I cannot find anything that tells me  
how to do this.  In the previous version of Tomcat I had put the above  
Context element into  
/usr/local/jboss/server/default/deploy/jbossweb-tomcat41.sar/META-INF/ 
jboss-service.xml.  But in Tomcat 5.0 it looks like that has moved to  
jbossweb-tomcat50.sar/server.xml.  When adding the Context element to  
my server.xml I get a 404 and a description that says: The requested  
resource (/watermarks/bar.jpg) is not available.
   Anyone know how I can get this to work?
   Thanks,
 -M@


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: getting Tomcat 5.0 to serve static content

2004-07-09 Thread Matthew Hixson
On Jul 8, 2004, at 11:56 PM, [EMAIL PROTECTED] wrote:

-Original Message-
From: Matthew Hixson
I'm using Tomcat 5.0.26 with JBoss 3.2.4.  I'm attempting
to upgrade from Tomcat 4.1.something that was included with
JBoss 3.2.3.  I cannot figure out how to configure a
context so that Tomcat will serve files from a specific
directory.  The directory contains images and should be
accessible outside of any specific webapp.  The files are
stored in /usr/local/watermarks and the URLs to them need
to look like http://mymachine.com/watermarks/bar.jpg.
   Context path=/watermarks docBase=/usr/local/watermarks/
   I've read all the docs I could find on the Apache Tomcat
site and used Google to find examples and I cannot find
anything that tells me how to do this.  In the previous
version of Tomcat I had put the above Context element
into
/usr/local/jboss/server/default/deploy/jbossweb-tomcat41.sar
/META-INF/
jboss-service.xml.  But in Tomcat 5.0 it looks like that
has moved to jbossweb-tomcat50.sar/server.xml.
If you read the docs enough times it suggests that the Context element
should be an anyName.xml, in {catalina.home}/conf/host/
Where it hides, just the Context element in an xml file per app.
(I found it useful to name the file after the app)
HTH DaveP
I did see that in the docs and tried it.  Still didn't work.  I don't 
know if I'm seeing strange behavior because of the way Tomcat is 
embedded in JBoss or what.
  -M@

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]