Settings examples of HAproxy

listen 80, allocate to 10004 and 10005 by roundrobin

frontend  main
		bind *:80
    default_backend             app

backend app
    server  app1
    server  app2

HTTPS with SSL offloading

frontend ssl_proxy
	mode http
	default_backend app
	bind *:443 ssl crt /etc/letsencrypt/live/

virtual host,,




backend ssl
	acl tako hdr(host) -m str
	use-server tako if tako
	server tako

	acl ika hdr(host) -m str
	use-server ika if ika
	server ika

	acl uni hdr(host) -m str
	use-server uni if uni
	server uni


ueda@scw-a:~$ /usr/sbin/haproxy -v
HA-Proxy version 1.7.5-2 2017/05/17
Copyright 2000-2017 Willy Tarreau <>
  • install
  • start: sudo systemctl start haproxy.service
  • restart: sudo systemctl restart haproxy.service
  • stop: sudo systemctl stop haproxy.service
  • status check: sudo systemctl status haproxy.service
Last Updated: 7/4/2020, 8:08:14 AM