I am trying to connect tomcat and apache so that
when I start tomcat it will also start apache. I have read all
the documentation, but it is unclear to me just where I need to
place the TOMCAT_HOME file inside apache so that they will recognize each
other. I am very green and need step by step, and/or file path and exact
placement. I am running win2000 platform. Thank you in advance for
hte advise. I look forward to giving back!!! .
Hello i�m supposing u`re using
mod_jserv. Its almost the same with mod_jk.
1� Download
apache
2� Download
Tomcat
3� Install
both of them, i�d rather put them in c:/apache and c:/tomcat
4� set your
JAVA_HOME enviroment, java path variable and your CLASSPATH. If u use w32
they go in the autoexec.bat and something like this:
SET JAVA_HOME=C:\jdk1.2.2 (the directory
where your jdk is. Under it is your bin folder)
SET
PATH=C:\jdk1.2.2\bin;%PATH%;
SET
PATH=C:\JSDK2.0\bin;%PATH%;
SET
CLASSPATH=.;;C:\jdk1.2.2\lib\tools.jar;C:\JSDK2.0\lib;C:\jdk1.2.2\lib;C:\JSDK2.0\lib\jsdk.jar;C:\tomcat\lib\classes12.zip;C:\tomcat\lib\servlet.jar
(no spaces in that instance!!!)
5� put the
mod_jserv.dll (that you should download also) in the modules folder of
Apache.
6� Edit
your http.conf file. Now you must tell apache to load the module, tell it that
it should work with tomcat and that the http request that goes to Tomcat
should by attended by Apache.
##Adding to Apache##
# 1 loadin the module#
LoadModule jserv_module
modules/ApacheModuleJServ.dll
ApJServManual on
ApJServDefaultProtocol
ajpv12
ApJServSecretKey DISABLED
ApJServMountCopy on
ApJServLogLevel
notice
ApJServDefaultPort 8007
AddType text/jsp .jsp
AddHandler jserv-servlet
.jsp
# Creating an alias of your app
Alias /eroski
"c:/tomcat/webapps/yourapp"
<Directory
"c:/tomcat/webapps/yourapp">
Options Indexes
FollowSymLinks
</Directory>
# Asociating the map of your app
ApJServMount
/yourapp/servlet /yourapp
# Noone getting in
WEB-INF and trashing around
<Location
"/yourapp/WEB-INF/">
AllowOverride
None
deny from all
</Location>
<Directory
"c:/tomcat/webapps/yourapp/WEB-INF/">
AllowOverride
None
deny from all
</Directory>
# Noone trashing
in META-INF
<Location
"/yourapp/META-INF/">
AllowOverride
None
deny from all
</Location>
<Directory
"D:/tomcat/webapps/yourapp/META-INF/">
AllowOverride
None
deny from all
</Directory>
#####################################################
# End of
extra in
httpd.conf
######################################################
And thats it Hope it
helps
Javi