httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From james <jcallo1...@gmail.com>
Subject [users@httpd] Newbie question about redirecting
Date Thu, 25 Oct 2012 00:42:00 GMT
I am new to the apache config and tomcat arena. forgive me if I am not 
giving all details. I can provide more if you let me know.

Problem Desc: I have 2 tomcat instances running on a linux box. And I 
have a apache webserver running on the same box. I have 2 web 
applications running, one on each tomcat.

  * tomcat 1 is the main page which is accesible via external world
    (internet) I don't want to mess with this. i can access it via
    example http://www.mymainpage.com/saa/products/welcome

  * tomcat 2 is my application; and I need to config this so that its
    accessible via internet. URL must be http://www.mymainpage.com/copa

I can access my application like this http://localhost:60334/copa, but I 
don't want this.
My setup is I am tunneling to the servers, so I have to setup tunnels to 
access my application.

What i Did so far?  - But I can't get this working. I am having problem 
with step 4 and 5 below. Would appreciate any help or hints
==================

Step 1
=========
Edit the workers.properties file

worker.list=ajp13, jkstatus, copa

worker.copa.port=60334
worker.copa.host=localhost
worker.copa.type=ajp13

Step 2
=======
  vim /class_saa/HTML/httpd/conf/mod_jk.conf

Ensured that the following line is there
     JkWorkersFile /class_saa/tomcat/conf/jk/workers.properties

Added

     JkMount /copa*       copa

Step 3
=======
vim /class_saa/HTML/httpd/conf/httpd.conf

Ensured that

<IfModule !mod_jk.c>
   LoadModule jk_module modules/mod_jk.so
</IfModule>

Step 4
=======
Not sure if I need to add Listen in httpd.conf file
or the /class_saa/HTML/httpd/conf/ssl.conf

vim /class_saa/HTML/httpd/conf/httpd.conf

Do I need to add ? into httpd.conf
Listen 192.168.230.200:60334

ssl.conf file does NOT have the NameVirtualHost

Do I need to add ? into httpd.conf ?
NameVirtualHost *:80

Do I need to add ? into httpd.conf ?
<VirtualHost 192.168.230.200:60334>
        ServerName wwwpop.nsof.isaac.nova.com
        ServerAlias isaac.nova.com *.isaac.nova.com
        DocumentRoot /class_saa/tomcat_services/OperatorToolbox/webapps/copa
        RewriteCond %{REQUEST_URI}      ^/copa$
        RewriteRule ^/(.*)$ $1/ [L,R]
        RewriteCond %{REQUEST_URI}      ^/copa/
        RewriteRule ^/copa/(.*)$ 
http://wwwpop.nsof.isaac.nova.com/copa/$1 [L,proxy]
</VirtualHost>


Step 5
======

Do I need to add following ? into my applications tomcat server.xml

<?xml version='1.0' encoding='utf-8'?>
<Server port="60335" shutdown="SHUTDOWN">
   <Service name="Catalina">

     <Connector port="8080" protocol="HTTP/1.1" 
connectionTimeout="20000"  redirectPort="8443" />
     <Connector port="60334" protocol="AJP/1.3" redirectPort="8443" />

     <Engine name="Catalina" defaultHost="localhost">
       <Host name="localhost"  appBase="webapps" unpackWARs="true" 
autoDeploy="true">
       </Host>
     </Engine>
   </Service>
</Server>



Mime
View raw message