is it possible for you to give me steps on what I should do please to make the virtual host work. I have domain name x.com, y.com and z.com (for example). For this what should the setup be so www.x.com, www.y.com and www.z.com take me to the servlet appropriate for each?
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------


On 12/21/2011 10:09 PM, Pid wrote:
On 20/12/2011 11:55, Pid wrote:
On 20/12/2011 09:21, r.sriram wrote:
Thanks Andre.
a few quick questions.

Questions with respect to your response:
Your response:

    <Host name="host1.domain1.com"... appBase="/path1/webapps/" ..>
    ...
    </Host>

    <Host name="host2.domain2.com"... appBase="/path2/webapps/" ..>
    ...
    </Host>

Questions:

  * which is the file where I should add these lines
  tomcat/conf/server.xml

  * Is host1:www. If not what is it?
I don't know what that means.

  * does path1, path2 etc. start at CATALINA_HOME?
See below.

  * Is there any other configuration change that I need to do
Yes, you will need to configure the connection between HTTPD and Tomcat,
using mod_proxy or mod_jk.

My Situation
Tomcat will be installed in directory let us say in Program Files (*86)
directory. That will have the web-inf directory.
WEB-INF, not web-inf.

Each domain has its own root, let us say: ..\domainX.com\httpdocs,
domainY.com\httpdocs etc.
In that case, there should also be:

  ..\domainX.com\appBase
  ..\domainY.com\appBase
Like I said here ^^^


Questions:

  * should I copy WEB-INF directory from C:\Program Files
    (x86)\apache-tomcat-6.0.33\webapps\ROOT\ to each of
    ..\domainX.com\httpdocs, domainY.com\httpdocs etc.
No. Definitely not.

A web application is not the same as a document root.

You should move the whole of ROOT to the appBase described above.
and here ^^^


p


On 12/19/2011 1:12 PM, André Warnier wrote:
r.sriram wrote:
Hello,
I am setting up my multiple domains on Go Daddy. In my current
in-house windows server my Tomcat is on Program Files (86) and the
ROOT is in C:\Program Files (x86)\apache-tomcat-6.0.33\webapps
directory. That is where WEB-INF is, that is what is my actual path
for all files that gets picked up by my web pages (including my
servlets).

In Go Daddy, there would be different ROOTs for each domain.
(../<domain>/httpdocs) But there would be one Tomcat installation.

can Tomcat be installed in Program Files (86), and the servlets, and
all the files needed for the domain be placed in ../<domain
name>/httpdocs?
Thanks.....Ram

Sure. Look at virtual hosts, here :
http://tomcat.apache.org/tomcat-7.0-doc/config/host.html
(and their appBase attribute)

<Host name="host1.domain1.com"... appBase="/path1/webapps/" ..>
...
</Host>

<Host name="host2.domain2.com"... appBase="/path2/webapps/" ..>
...
</Host>
etc..

I suggest to leave the default<Host name="localhost" ..>  as it is,
and just add the others.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org






---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to