By Clay Li on Sunday, 24 May 2020
Category: Feature

How to Configure Calem with a Proxy

​A proxy server such as a load balancer may be used with Calem to enforce security policy or to distribute load among Calem application servers. Some configuration changes are necessary for Calem to work with a proxy server.

1. Calem URL by HTTPs

If your proxy server is to terminate SSL and Calem is accessed with plain HTTP, one needs to tell Calem to always use HTTPs by adding the following line to your Calem_Home/server/conf/calem.custom.php.

2. Calem URL by Proxy

Calem uses internally configured URLs sometimes for reports and presentation. One needs to define both URLs to use with the proxy server by adding the following two lines to your calem.custom.php (replace the internal IP and external URL by your service configuratiton).

 3. Health Check

The proxy server should use HTTP "HEAD" request to check the status of Calem. For instance, a proxy server does health check of Calem every 5 seconds by sending an HTTP "HEAD" request to https://192.168.31.235 (replace the IP with that of your own Calem app server).

If HTTP "HEAD" request is not available to do health check use the following URL: https://192.168.31.235/status (replace the IP with that of your own Calem app server).

Doing health check by HTTP "GET" at Calem login URL such as https://192.168.31.235 will cause Calem app server to kick off processes for login and is not recommended.

 4. Web Client Javascript Loading

This configuration uses the best practice for JavaScript loading and may be necessary based on proxy server configuration. 

Additional Resources