I'm a newbie with this but here's what I got...

The jakarta documentation says the Host element represents a Virtual Host.  One or 
more Host elements are nested inside an Engine element.

..and on an Engine element it says, Exactly one Engine element must be nested inside a 
Service element, following all of the corresponding Connector elements associated with 
a Service.

..and on a Connector it says, HTTP/1.1 and Warp are typical connectors.


So in the server.xml file, I used the Tomcat-Apache Service, and placed some Warp 
Connectors (making sure they utilized unique ports), one for each one of my virtual 
hosts within the service as follows:


  <!-- Define an Apache-Connector Service -->
  <Service name="Tomcat-Apache">

    <Connector className="org.apache.catalina.connector.warp.WarpConnector"
     port="8008" minProcessors="5" maxProcessors="75"
     enableLookups="false"
     acceptCount="10" debug="0"/>

    <Connector className="org.apache.catalina.connector.warp.WarpConnector"
     port="8015" minProcessors="5" maxProcessors="75"
     enableLookups="false"
     acceptCount="10" debug="0"/>

    <!-- Replace "localhost" with what your Apache "ServerName" is set to -->
    <Engine className="org.apache.catalina.connector.warp.WarpEngine"
     name="www.myServer.com" debug="99" appBase="webapps">


Then I added in my Hosts (Default Host as in server.xml and others for each virtual 
host).


It was only when I used this configuration that the entries in httpd.conf were 
accepted and responded ok.  Example from httpd.conf follows:


<VirtualHost 192.168.1.2>
    ServerAdmin ...
    DirectoryIndex index.html
    DocumentRoot ...
    ServerName www.virtualhost1.org
    WebAppConnection apoWarpConn  warp www.virtualhost1.org:8015
    
    WebAppDeploy   myapp       apoWarpConn    /apps/
    WebAppDeploy   manager      apoWarpConn   /manager/

    ErrorLog ...
    CustomLog ...
</VirtualHost>


At this point, I even removed the Tomcat-Standalone Connector Service from server.xml 
and all seems to be responding as I want.


Nevertheless beware... this outcome is more the result of trial & error than a logical 
understanding of the components on my part.


 HTH
/j-p.





On Thu, 7 Feb 2002, chad kellerman wrote:

> Hey guys,
> 
>     I am stuck again.  This time with the virtual host section in apache.  Here is 
>what I got:
> 
>  <VirtualHost jakarta.domain.com>
> WebAppConnection warpConnection warp localhost:8008
> WebAppDeploy examples warpConnection /home/jak/jakarta-www/examples/
> User jak
> Group jakartagrp
> ServerName jakarta.domain.com
> ServerAdmin [EMAIL PROTECTED]
> DocumentRoot /home/jak/jakarta-www
> TransferLog /home/jak/jakarta-logs/access-log
> ScriptAlias /cgi-bin/ /home/jak/jakarta-www/cgi-bin/
> </VirtualHost>
> 
> an /etc/httpd/bin/apachectl configtest says it does not like
> 
> WebAppDeploy examples warpConnection /home/jak/jakarta-www/examples/
> 
> 
>       I am trying to get tomcat working with multiple virtual hosts.
> 
> I have the module loading fine.  But I haven't found how to configure httpd.conf for 
>tomcat as well as the server.xml file.
> 
>      Anyone get this working properly?  I on red hat.  But I would think the config 
>should be similar on other os's..
> 
> Thanks for the info,
> 
> Chad
> 
> 
> 
> --
> To unsubscribe:   <mailto:[EMAIL PROTECTED]>
> For additional commands: <mailto:[EMAIL PROTECTED]>
> Troubles with the list: <mailto:[EMAIL PROTECTED]>
> 


-----------------------
 JUSTATEST Art Online
  www.justatest.com




--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>

Reply via email to