Tomcat+Apache HOWTO by Costin Manolache Anil Vijendran $Revision$ $Date$ This document describes how to setup Tomcat to run with Apache. For now this document describes how to run Tomcat 3.0 with Apache 1.3.9. Check the section on "Tested Configurations" for other Apache/Tomcat versions. ------------------------------------------------------------------------ Table of Contents 1. Introduction 2. Installation 2.1 Apache 1.3.9 2.2 Tomcat 3.0 2.3 Testing Your Configuration 2.4 Adding Contexts 3. Tested Configurations 4. More information, feedback, bugs ------------------------------------------------------------------------ 1. Introduction This document is intended to get you started using Tomcat with Apache until we have Apache and Tomcat as one integrated release. If you ran into any gotchas while following these instructions, please let us know so we can keep this document updated. In the rest of the document, we use /path/to/apache-1.3.9 to mean the path to the Apache 1.3.9 installation and /path/to/tomcat3.0 to mean the path to the Tomcat 3.0 installation. We will assume you are running Apache on the default port (80). 2. Installation 2.1 Apache 1.3.9 * Download and install the Apache 1.3.9 binary for your platform from http://www.apache.org/dist/binaries * Configure the default HTTP listener port in your /path/to/apache-1.3.9/conf/httpd.conf file. * Make sure ServerName in /path/to/apache-1.3.9/conf/httpd.conf contains the name of your host. 2.2 Tomcat 3.0 * Download and install Tomcat 3.0 for your OS/platform from http://jakarta.apache.org/builds/tomcat/release/v3.0// * Download mod_jserv for your platform from http://jakarta.apache.org/builds/tomcat/release/v3.0///modules and copy it into /path/to/apache-1.3.9/modules. * Edit /path/to/apache-1.3.9/conf/httpd.conf and add the following line at the end: Include /path/to/tomcat3.0/etc/tomcat.conf 2.3 Testing Your Configuration * Restart Apache (apachectl restart or Apache -k restart on Win32) * Make sure http:// is working * Try http:///examples -- you should see the Tomcat examples. 2.3 Adding Contexts There's two different ways you can add contexts to this configuration: (a) * Add to /path/to/tomcat3.0/etc/tomcat.conf: ApJservMount / /root * restart Apache. (b) * Create /path/to/apache-1.3.9/htdocs/ * Install all the files of that context into that directory. * Make sure /path/to/tomcat3.0/server.xml points to /path/to/apache-1.3.9/htdocs/ * Add to /path/to/tomcat3.0/etc/tomcat.conf: ApJservMount //servlet /root AllowOverride None deny from all 3. Tested Configurations Apache 1.3.9 + Tomcat 3.0 has been tested on the following OSes: * Linux (RedHat 6.1) on SPARC and Intel * Solaris 2.6 on SPARC * Windows NT SP 4 4. More information, feedback and bugs Please send bug reports (both on Tomcat and on this document) to tomcat-dev@jakarta.apache.org. If you tested this on a platform/os that is not listed here, please either update this file (if you have CVS commit access on Jakarta) or send a note to tomcat-dev@jakarta.apache.org.