How to redirect Pipeline Pilot HTTP calls to the secure HTTPS port

You can configure Pipeline Pilot to only accept calls through the secure port (default is 9943) using HTTPS by changing the "Server Port Usage" setting in the Admin Portal under Setup > Server Configuration to "SSL Only". It is recommended to configure Pipeline Pilot this way for security reasons. But the drawback is that connections will then fail if users tries to connect using HTTP as they are not automatically redirected.

If you want to keep the HTTP port active and redirect any calls to this to the HTTPS port, you need to provide some directives in a configuration file. The recommendation is to place custom configuration files in "/web/conf/" so that the configuration is not overwritten by the installer during e.g. an upgrade.

Attached is an example configuration file (redirect_http.txt) that will:

A - Add a listener to port 80 (the default HTTP port) and redirect any calls to this to the HTTPS port, 9943.

B - Redirect any calls to port 9944 (the default Pipeline Pilot HTTP port) to the HTTPS port.

If you rename this file to e.g. "redirect_http.conf " and drop it into the "/web/conf/" folder, you will have the following redirects:
http://servername.domain.com => https://servername.domain.com:9943
http://servername.domain.com:9944 => https://servername.domain.com:9943

NOTES:

  • You need to edit the file and use the servername and port numbers applicable to your specific server.
  • The listener to port 80 was added for convenience so that users don't have to enter this in the URL but this port might already be in use by some other service on your server. If that is the case, you need to remove the Listener and VirtualHost directives for this port.
  • The reason there is no Listener directive for port 9944 and 9943 in this file is that these are already defined elsewhere in the default configuration so we only need to add the redirects for these ports.