From 346562ab6aed8c49cb84a6a207a209e6913e9ef4 Mon Sep 17 00:00:00 2001 From: Maysa Macedo Date: Tue, 11 Feb 2025 13:08:31 -0300 Subject: [PATCH] Enforce VIPs to be collocated at the same host --- .../on-prem/files/keepalived-keepalived.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/templates/master/00-master/on-prem/files/keepalived-keepalived.yaml b/templates/master/00-master/on-prem/files/keepalived-keepalived.yaml index 159321e593..a97dd7fe32 100644 --- a/templates/master/00-master/on-prem/files/keepalived-keepalived.yaml +++ b/templates/master/00-master/on-prem/files/keepalived-keepalived.yaml @@ -69,6 +69,17 @@ contents: fall 2 } + {{- if and (eq .Infra.Status.PlatformStatus.Type "OpenStack") (or (eq .IPFamilies "DualStack") (eq .IPFamilies "DualStackIPv6Primary")) }} + vrrp_sync_group VG1 { + group { + {{`{{ range $i, $config := .Configs }}`}} + {{`{{ .Cluster.Name }}`}}_API_{{`{{$i}}`}} + {{`{{ .Cluster.Name }}`}}_INGRESS_{{`{{$i}}`}} + {{`{{ end }}`}} + } + } + {{- end}} + {{`{{ range $i, $config := .Configs }}`}} {{`{{$nonVirtualIP := .NonVirtualIP}}`}}