1 # Config from Blog-article "How to Run HAProxy with Docker"
7 timeout http-request 10s
11 stats socket ipv4@:8401 level admin
22 default_backend random
23 use_backend %[req.hdr(X-Shard),map(/usr/local/etc/haproxy/sharding.map)]
26 server b1 backend-1:8080 check
27 server b2 backend-2:8080 check
28 server b3 backend-3:8080 check
31 server b1 backend-1:8080 check
34 server b2 backend-2:8080 check
37 server b3 backend-3:8080 check