Here is my config file
listen minecraft
bind :25565
mode tcp
balance leastconn
option tcp-check
server minecraft1 example.com:25570 send-proxy
But it fails to start with this error
systemctl status haproxy.service
● haproxy.service - HAProxy Load Balancer
Loaded: loaded (/lib/systemd/system/haproxy.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Sat 2019-06-01 23:43:48 HKT; 5s ago
Docs: man:haproxy(1)
file:/usr/share/doc/haproxy/configuration.txt.gz
Process: 3190 ExecStart=/usr/sbin/haproxy -Ws -f $CONFIG -p $PIDFILE $EXTRAOPTS (code=exited, status=1/FAILURE)
Process: 3183 ExecStartPre=/usr/sbin/haproxy -f $CONFIG -c -q $EXTRAOPTS (code=exited, status=0/SUCCESS)
Main PID: 3190 (code=exited, status=1/FAILURE)
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Main process exited, code=exited, status=1/FAILURE
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Failed with result ‘exit-code’.
Jun 01 23:43:48 vps1 systemd[1]: Failed to start HAProxy Load Balancer.
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Service hold-off time over, scheduling restart.
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Scheduled restart job, restart counter is at 5.
Jun 01 23:43:48 vps1 systemd[1]: Stopped HAProxy Load Balancer.
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Start request repeated too quickly.
Jun 01 23:43:48 vps1 systemd[1]: haproxy.service: Failed with result ‘exit-code’.
Jun 01 23:43:48 vps1 systemd[1]: Failed to start HAProxy Load Balancer.