Skip to content

Instantly share code, notes, and snippets.

@sirkirby
Created October 3, 2023 21:41
Show Gist options
  • Save sirkirby/06d2120d463668de59c281e195ca3d4c to your computer and use it in GitHub Desktop.
Save sirkirby/06d2120d463668de59c281e195ca3d4c to your computer and use it in GitHub Desktop.
HAProxy Config
sudo nano /etc/haproxy/haproxy.cfg
# add the following config, ctrl-x then y to exit and save
frontend k3s-frontend
bind *:6443
mode tcp
option tcplog
default_backend k3s-backend
backend k3s-backend
mode tcp
option tcp-check
balance roundrobin
default-server inter 10s downinter 5s
server server1 192.168.1.10:6443 check
server server2 192.168.1.11:6443 check
server server3 192.168.1.12:6443 check
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment