global_defs { router_id {{ .RouterID }} script_user root enable_script_security vrrp_garp_interval 0 vrrp_gna_interval 0 } vrrp_script chk_edgeguard { script "/usr/lib/edgeguard/keepalived-check.sh" interval 2 weight -50 fall 3 rise 2 } vrrp_instance VI_1 { state {{ .State }} interface {{ .Interface }} virtual_router_id {{ .RouterID }} priority {{ .Priority }} advert_int 1 {{ if .SrcIP }} unicast_src_ip {{ .SrcIP }} unicast_peer { {{ .PeerIP }} } {{ end }} authentication { auth_type PASS auth_pass {{ .AuthPass }} } virtual_ipaddress { {{ .VIP }} } track_script { chk_edgeguard } notify_master "/usr/lib/edgeguard/keepalived-master.sh" notify_backup "/usr/lib/edgeguard/keepalived-backup.sh" notify_fault "/usr/lib/edgeguard/keepalived-backup.sh" }