The objective of this excercise is to get Apache and Tomcat connected, we want Apache the default web server that serves the port 80 to forward requests to Tomcat - Railo.
The end goal for me in this case, is to get Apache / Tomcat / Railo to serve up http://personal.ecommerce2
Note, this post is really based on very excellent series on installing multiple ColdFusion servers by Dave Shuck: Installing-Railo-under-Tomcat-with-Apache-webserver
Step 1 - Download the Apache - Tomcat connector
Get the connector from http://tomcat.apache.org/connectors-doc/
I’m getting the Windows one since uhm.. I’m setting up my windows environment. Just click on binaries link on that page and find the one for Windows (32 bit in my case) - the latest one available is: mod_jk-1.2.28-httpd-2.2.3.so and so I grabbed that one.
I put the .so file into the :
C:\Program Files\Apache Software Foundation\Apache2.2\modules which my Apache installation folder.
Step 2 - Configure the connector
And then I created workers.properties file and put it on
C:\Program Files\Apache Software Foundation\Apache2.2\ folder
Step 3 - Adding the site to Hosts, Apache and Tomcat
Next as usual, I added personal.ecommerce2 to my hosts file.
I then added the site definition to my Apache vhost file, which in my case located on:
C:\Program Files\Apache Software Foundation\Apache2.2\conf\extra\httpd-vhosts.conf
Now, I restart Apache and restart Tomcat and go to the URL and it's there!!
This particular site is using ColdBox with URL rewriting on and I couldn't go far navigating the pages because Tomcat doesn't support URL rewriting out of the box.
So for the next challenge for me is to figure out how to get URL rewriting to work on Tomcat - which apparently again not a hard thing to do.. but we'll see..