Javi

haproxy: configuración básica

Aug 13th, 2014
291
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. frontend services
  2. bind 0.0.0.0:80
  3. mode http
  4. acl url_private path_beg /private
  5. acl url_public path_beg /public
  6. use_backend public_servers if url_public
  7. use_backend private_servers if url_private
  8. default_backend other_servers
  9.  
  10. backend public_servers
  11. mode http
  12. balance roundrobin
  13. option httpchk GET /health
  14. server public1 127.0.0.1:8000 check
  15. server public2 127.0.0.1:9000 check
  16.  
  17. backend private_servers
  18. mode http
  19. balance roundrobin
  20. option httpchk GET /health
  21. server private1 127.0.0.1:8500 check
  22. server private2 127.0.0.1:9500 check
  23.  
  24. backend other_servers
  25. mode http
  26. balance roundrobin
  27. option httpchk GET /health
  28. server other1 127.0.0.1:7000 check
Advertisement
Add Comment
Please, Sign In to add comment