Guest User

Untitled

a guest
Sep 2nd, 2016
327
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.94 KB | None | 0 0
  1. defaults
  2. log global
  3. mode http
  4. option httplog
  5. option dontlognull
  6. timeout connect 5000
  7. timeout client 10000
  8. timeout server 10000
  9.  
  10. listen stats :70
  11. stats enable
  12. stats uri /
  13. #frontend blancer for web.example.com
  14. frontend balancer
  15. bind localhost:80 localhost:81
  16. mode http
  17. use_backend web if { chat.abc.com }
  18. use_backend test if { api.abc.com }
  19.  
  20.  
  21. #backend config for web
  22. backend web
  23. # mode http
  24. option forwardfor
  25. # http-request set-header X-Forwarded-Port %[dst_port]
  26. balance roundrobin
  27. server weba weba:80 check
  28. server webb webb:80 check
  29. # server webc webc:80 check
  30. # option httpchk OPTIONS * HTTP/1.1\r\nHost:\ localhost
  31. option httpchk GET /
  32. # http-check expect status 200
  33. #backend config for for test
  34. backend test
  35. # mode http
  36. option forwardfor
  37. balance roundrobin
  38. server test1 test1:81 check
  39. server test2 test2:81 check
  40. option httpchk GET /
  41. # http_check expect status 200
Add Comment
Please, Sign In to add comment