_ConfigureApacheHTTPServer
Step 2: Configure Apache HTTP Server
Apache uses something called Modules, these can be enabled or disabled and are essentially plugins that change the functionality of the server.
mod_proxy is an example of these modules, mod_proxy implements a proxy, gateway or cache for Apache while also allowing multiple virtual hosts on a single client.
Another option available is the use of mod_jk, this introduces the ability to forward requests to an application via the AJP protocol, for more details on this option please refer to the following documentation;
The preferred configuration is Proxying Atlassian server applications with Apache HTTP Server (mod_proxy_http). This works with any application server, and together with mod_proxy_html
allows complex URL rewriting to deal with different application paths on the web server and the application server.
In addition, note that mod_jk and mod_jk2 are other commonly used AJP modules and not covered by this documentation.
More information
- The mod_proxy_html site has documentation and examples on the use of this module.
- Apache Week has a tutorial that deals with a complex situation involving two applications and ProxyHTMLURLMap.
Apache Configuration file
It's important to note that Apache's default configuration varies significantly between various Linux distributions, Debian and Ubuntu distributions refer to Apache as 'Apache2' with the configuration files being stored in the /etc/apache2/
directory and named apache2.conf. Other distributions including CentOS and Fedora refer to Apache as 'httpd' with the configuration files stored in the /etc/httpd/
directory and the configuration file named httpd.conf. Windows also follows the httpd.conf format.
Enable the Proxy modules
Now enable mod_proxy in Apache, and proxy requests to the application server by adding the example below to your Apache configuration file.