Apache HTTP Co-Service Configuration

Apache HTTP Co-Service Configuration


Installation of Apache can be done through any number of means, depending on the software package on hand, and the target OS used. Please consult the Apache documentation for installation information.


All steps require use of a command shell. The example posted below is working as root user, but some OS's are not enabled for root user access. The root user may have do be enabled on the target machine, otherwise commands must be prepended with "sudo", or whatever method required for editing service files, starting and stopping services, etc.

Locate the httpd.conf file

The httpd.conf file (sometimes alternatively, the apache2.conf file) is the configuration file for Apache. Locate this file on the target machine. For purposes of this illustration, the httpd.conf file name will be used.

Alternatively "find" will do the same thing;

In this case, the "/private/etc/apache2/httpd.conf" file is the one we are interested in.

Include the TACTIC configuration file in Apache

For isolation of configuration options for editing purposes, the TACTIC configuration file is a single file which should be referred to by the Apache configuration file. In this case, the default "tactic.conf" file will be used. The file is included at the end of this document.

Find out if the httpd.conf file has an "Include" statement that refers to a directory the TACTIC Apache configuration file can be put in.

In this case, the line at the bottom is the one that is required;

If there is no such include, then a line can be added to the httpd.conf file.

In the above example, there is a reference to a directory wild-card configuration inclusion. Essentially then, any files with the suffix ".conf" will be activated. This is where the TACTIC configuration file will be stored. Either the default configuration file can be used with some editing, due to the variations in location of the TACTIC service application.

Instruct Apache to proxy static files

For purposes of efficiency, Apache will proxy files that are static. In the tactic.conf file, there are 2 major directives that are of concern regarding directory access. There is the directives that enable the TACTIC GUI widgets to work,

The second set is:

In the default example, the TACTIC application is stored at "/home/apache/tactic" while the assets are stored at "/home/apache/assets" The directives here allow Apache access to proxy these file locations for TACTIC.

Instruct Apache to rewrite the "/tactic" URL subpath

Since Apache is serving only static files, it can be configured to serve the dynamic content served by TACTIC using a proxy.

To enable the Apache proxy service, the tactic.conf file must contain directives that enable the proxy and rewrite modules to serve the TACTIC service.

In this example, the TACTIC service is located on the same machine, on port 8081. All URL requests that have a "/tactic" or "/projects" in the URL will be redirected to the TACTIC service, which by default is on port 8081.

To effectively use load-balancing on this machine, replace it with the following configuration instead:

The file, /home/apache/sites/load_balance.txt contains

The Apache configuration files have now been modified to proxy and rewrite TACTIC requests.

Restart the Apache Service

Apache needs to be restarted for the configuration changes to take effect. Most Apache installations have a "apachectl" command. To restart apache, use;

apachectl restart

Once Apache has been restarted, it should be serving TACTIC requests.


At this point Apache should be configured to proxy TACTIC service requests to the TACTIC service, while leaving all other requests to Apache itself.