Page 1 of 1

Apache Reverse Proxy Load Balancer

PostPosted: 17. July 2019 07:56
by al4nzonealor
I have a proxy server ee.ee.ee.ee that is configured to load balance my superset application sitting on 2 servers xx.xx.xx.xx:8088 and yy.yy.yy.yy:8088 and druid sitting on zz.zz.zz.zz:8888.

What I want is to be able to reference my proxy server with either /superset or /druid and each will re-direct me to each of the applications.

As per the configs, setting the ProxyPass / balancer://superset/ redirects me to the superset by default as for both applications, there are no paths to access them ie they are being accessed directly eg xx.xx.xx.xx:8088 and yy.yy.yy.yy:8088 and not xx.xx.xx.xx:8088/superset and zz.zz.zz.zz:8888/druid.

The load balance manager is already configured in the httdp.conf file.

The code is as below for the virtual host:

NameVirtualHost *:80
<VirtualHost *:80>

<Proxy balancer://superset>
BalancerMember http://xx.xx.xx.xx:8088
BalancerMember http://yy.yy.yy.yy:8088
</Proxy>

<Proxy balancer://druid>
BalancerMember http://zz.zz.zz.zz:8888
</Proxy>

ProxyPreserveHost On

ProxyPass /bigdata-balancer-manager !
ProxyPass /superset balancer://superset/ nofailover=off
ProxyPassReverse /superset balancer://superset/

ProxyPass /druid balancer://druid/ nofailover=off
ProxyPassReverse /druid balancer://druid/

</VirtualHost>