Download
the Windows binary distribution (.msi file)
from http://archive.apache.org/dist/httpd/binaries/win32/
.
Run the MSI file that you downloaded.
By default, the Apache HTTP Server is installed on port 80. If some other server is using port 80, you must change the port on which Apache listens for requests in the <apache-httpd- install>\conf\httpd.conf file. Search for the directive Listen in the configuration file and change the port number by changing this directive to <new-port-num>.
Ensure that the Apache HTTP server is working correctly.
To do so, enter the URL for the Apache server (http://<hostname>:<port-number>
)
in a Web browser. The server should display a page in the browser
that says, “It Works!”.
workers.tomcat_home: Set to the Tomcat installation directory.
workers.java_home: Set to the JDK path.
Download
the mod_jk module for Apache from https://archive.apache.org/dist/tomcat/tomcat-connectors/jk/binaries/win32/jk-1.2.23/
.
This module exists as mod_jk-apache-2.2.4.so.
Place the module in the <apache-httpd-install>\modules\ folder.
Add the mod_jk module by appending the following line of text to the <apache-httpd -install>\conf\httpd.conf file: LoadModule jk_module modules/mod_jk-apache-2.2.4.so
Using the JkMount command, add the context names that you want to direct to Tomcat: JkMount /robohelp/* ajp13 JkMount /th robohelp ajp13
<Engine>
......
<Host>
................
</Host>
<Listener className="org.apache.jk.config.ApacheConfig"
modJk=<apache-install-folder>\modules\<mod_jk_module>
workersConfig=<apache install folder>\conf\workers.properties />
</Engine>
modJK and workersConfig must have appropriate values. For example:
<Listener className="org.apache.jk.config.ApacheConfig"
modJk="C:\Program Files\Apache Software Foundation\Apache2.2\modules\mod_jk-apache-2.2.4.so"
workersConfig="C:\Program Files\Apache Software Foundation\Apache2.2\conf\workers.properties" />
Stop the Apache HTTP Web server if it is running.
Restart Tomcat. The <tomcat-install-folder>\conf\auto\mod_jk.conf file is generated. This file decides which URLs Apache passes to Tomcat.
Add “Include <tomcat-install-folder>\conf\auto\mod_jk.conf” at the start of the httpd.conf file.
Run the command prompt.
Go to <apache-install-folder>\bin.
Run httpd.exe to check for errors.
..............
<Connector port="9090" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" URIEncoding="UTF-8" />
............
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8" />
............
At the command prompt, change to the [JAVA_HOME]\bin directory.
Run the following command: keytool -genkeypair -alias tomcat -keyalg RSA -keystore key1 -validity 30
A new keystore file is created in the home directory of the user who runs the command. To specify a different location or file name, modify the command to add the -keystore parameter followed by the complete path of the keystore file. You will also need to specify this new path in the server.xml configuration file, as described in Step 6.
Enter the keystore password.
Enter the appropriate values when prompted for your personal and organization information.
When prompted, enter the Tomcat key password.
Modify the server.xml file for your Tomcat server and add the following text, replacing the bold text with appropriate values for your system:
<Connector port=[port number] protocol="HTTP/1.1" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false"
strategy="ms"
address="${jboss.bind.address}"
keystoreFile="${jboss.server.home.dir}/conf/THE_KEYSTORE_NAME"
keystorePass="PASSWORD_FOR_THE_KEYSTORE"
truststoreFile="${jboss.server.home.dir}/conf/THE_KEYSTORE_NAME"
truststorePass="PASSWORD_FOR_THE_KEYSTORE"
sslProtocol="TLS"/>
Restart Tomcat.