Hy all,

I have a problem to configure Apache and Tomcat under WebCp on a Virtual Server.
Actually Apache provides to static resources (via webcp for multidomains) and Tomcat to dynamic resources (via server.xml configuration) and everything is OK.


The question is: how can I configure Apache to pass the process of both static and dynamic resources to Tomcat only for a specific domains?

I tried to put an .htaccess file under /home/<myspecificdomain>/web like this one (see above) to redirect the execution of static and dynamic resources to tomcat:
------------------------------------------------------------------------------------
RewriteEngine on
RewriteRule ^(.*\.*) http://<myspecificdomaib>:8087/$1 [P]
------------------------------------------------------------------------------------


then I set a tomcat connector listening on :8087 like this one:
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[....]

<Service className="org.apache.catalina.core.StandardService" debug="0" name="Tomcat-Standalone">
<Connector className="org.apache.coyote.tomcat4.CoyoteConnector" acceptCount="10" bufferSize="2048" connectionTimeout="20000" debug="0" enableLookups="true" maxProcessors="75" minProcessors="5" port="8087" protocolHandlerClassName="org.apache.coyote.http11.Http11Protocol" proxyPort="0" redirectPort="8443" scheme="http" secure="false" tcpNoDelay="true" useURIValidationHack="false">
<Factory className="org.apache.catalina.net.DefaultServerSocketFactory"/>
</Connector>


<Connector className="org.apache.coyote.tomcat4.CoyoteConnector" acceptCount="10" bufferSize="2048" connectionTimeout="20000" debug="0" enableLookups="true" maxProcessors="75" minProcessors="5" port="8009" protocolHandlerClassName="org.apache.jk.server.JkCoyoteHandler" proxyPort="0" redirectPort="8443" scheme="http" secure="false" tcpNoDelay="true" useURIValidationHack="false">
<Factory className="org.apache.catalina.net.DefaultServerSocketFactory"/>
</Connector>


<Engine className="org.apache.catalina.core.StandardEngine" debug="0" defaultHost="localhost" mapperClass="org.apache.catalina.core.StandardEngineMapper" name="Standalone">
<Host className="org.apache.catalina.core.StandardHost" appBase="webapps" autoDeploy="true" configClass="org.apache.catalina.startup.ContextConfig" contextClass="org.apache.catalina.core.StandardContext" debug="0" deployXML="true" errorReportValveClass="org.apache.catalina.valves.ErrorReportValve" liveDeploy="true" mapperClass="org.apache.catalina.core.StandardHostMapper" name="www.victoriasrl.it" unpackWARs="true">
<Alias>victoriasrl.it</Alias>
<Context className="org.apache.catalina.core.StandardContext" cachingAllowed="true" charsetMapperClass="org.apache.catalina.util.CharsetMapper" cookies="true" crossContext="false" debug="0" displayName="Tomcat Manager Application" docBase="/usr/local/web/tomcat/server/webapps/manager" mapperClass="org.apache.catalina.core.StandardContextMapper" path="/manager" privileged="true" reloadable="false" swallowOutput="false" useNaming="false" wrapperClass="org.apache.catalina.core.StandardWrapper">
<ResourceEnvRef>
<name>users</name>
<type>org.apache.catalina.UserDatabase</type>
</ResourceEnvRef>
</Context>
[.............]
</Host>
<Logger className="org.apache.catalina.logger.FileLogger" debug="0" directory="logs" prefix="catalina_log." suffix=".txt" timestamp="true" verbosity="1"/>
<Realm className="org.apache.catalina.realm.UserDatabaseRealm" debug="0" resourceName="UserDatabase" validate="true"/>
</Engine>
</Service>
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------


Everything goes OK for dynamic resources, but when I try to get a static resource (image or html file) I receive a 403 error permission denied.
So I tried to modify the permission on a FS, but without success...


any idea?

thank in advance for any suggestion, regards

Maurizio Betti




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



Reply via email to