Files
learn-devops/ansible/roles/haproxy_static_pods/templates/keepalived.conf.j2
github-actions[bot] 52a3d0eb3b Add L2 Load Balancer (#16)
Co-authored-by: Fedor Batonogov <f.batonogov@yandex.ru>
2024-07-27 11:35:15 +03:00

30 lines
578 B
Django/Jinja

! /etc/keepalived/keepalived.conf
! Configuration File for keepalived
global_defs {
router_id LVS_DEVEL
}
vrrp_script check_apiserver {
script "/etc/keepalived/check_apiserver.sh"
interval 3
weight -2
fall 10
rise 2
}
vrrp_instance VI_1 {
state MASTER
interface eth0
virtual_router_id 51
priority 101
authentication {
auth_type PASS
auth_pass {{ lookup('password', 'secrets/kubeadm/keepalived/auth_pass length=64') }}
}
virtual_ipaddress {
10.0.75.80/24
}
track_script {
check_apiserver
}
}