HAproxy to web host sub directory?
Posted
by
daemonza
on Server Fault
See other posts from Server Fault
or by daemonza
Published on 2012-03-20T07:51:03Z
Indexed on
2014/08/25
10:22 UTC
Read the original article
Hit count: 159
haproxy
Hi for reasons outside my control, I need to load balance two servers, that run a non-virtual host enabled app on IIS.
Normally in HAProxy I would load balance servers(apache, tomcat, etc) like this :
acl is_www_example_com hdr_end(host) -i www.example.com
use_backend www_example_com if is_www_example_com
backend www_example_com
balance roundrobin
cookie SERVERID insert nocache indirect
option httpchk HEAD / HTTP/1.0
option httpclose
option forwardfor
server node1 192.168.1.1:80 cookie node1
server node1 192.168.1.2:80 cookie node1
Which will route to the node 1 and node 2 server and serve up the virtual host site. if I need to route to www.example.com/application/data
How would I be able to do it, with the above example, if at all even possible?
© Server Fault or respective owner