matador
Thu, 06 Oct 2005 20:31:08 -0700
matador <[EMAIL PROTECTED]> wrote in [EMAIL PROTECTED]: > ok so i define my connection pools etc in a context.xml for localhost: > > C:\Tomcat 5.5\conf\Catalina\localhost\context.xml > > and it works. > > but when the site is accessed from the virtual host defined in > server.xml, then the context.xml (deployed as described below) does > not ever see the connection pools > > i tried it as follows, no joy: > > C:\Tomcat 5.5\conf\Catalina\struts.acme.com\context.xml > C:\Tomcat 5.5\conf\Catalina\struts.acme.com\context.xml.default > C:\Tomcat 5.5\conf\Catalina\struts.acme.com\struts.xml > C:\Tomcat 5.5\conf\Catalina\struts.acme.com\struts.acme.com.xml > > only ever works from server.xml > > is there a workaround? i know im not the only one: > http://www.junlu.com/msg/187453.html
got it to work:
here is how:
tomcat 5.5.9
windows
server.xml
<Engine
defaultHost="localhost"
name="Catalina">
<Realm className="org.apache.catalina.realm.UserDatabaseRealm"/>
<Host
appBase="webapps/acme"
name="struts.acme.com">
<Alias>struts.acme.com</Alias>
</Host>
<Host
appBase="webapps"
name="localhost">
</Host>
</Engine>
add this file:
C:\Tomcat 5.5\conf\Catalina\struts.acme.com\ROOT.xml
<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" antiResourceLocking="true" docBase=""
reloadable="true" workDir="work\Catalina\struts.acme.com\_">
<ResourceLink global="jdbc/...
<Resource auth="Container" name="jdbc/...
<WatchedResource>WEB-INF/web.xml....
</Context>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]