Add Autodetect config for IPv6 and removed on IPv4 if CIDR not configured

Signed-off-by: Roberto Bonafiglia <roberto.bonafiglia@suse.com>
pull/592/head
Roberto Bonafiglia 2025-01-09 17:12:12 +01:00 committed by Roberto Bonafiglia
parent 6e6db0d4a3
commit 24733707b3
2 changed files with 11 additions and 2 deletions

View File

@ -1,6 +1,6 @@
--- charts-original/templates/crs/custom-resources.yaml
+++ charts/templates/crs/custom-resources.yaml
@@ -2,7 +2,34 @@
@@ -2,7 +2,43 @@
{{ $installSpec := omit .Values.installation "enabled" }}
{{ $_ := set $installSpec "imagePullSecrets" (include "tigera-operator.imagePullSecrets" . | fromYamlArray) }}
{{ $_ := set $installSpec "kubeletVolumePluginPath" .Values.kubeletVolumePluginPath }}
@ -27,11 +27,20 @@
+{{ $_ := set $calicoNetwork "ipPools" $finalIpPoolList }}
+{{ end }}
+{{ if empty .Values.installation.calicoNetwork.nodeAddressAutodetectionV4 }}
+{{ if not (empty .Values.global.clusterCIDRv4) }}
+{{ $calicoNetwork := get .Values.installation "calicoNetwork" }}
+{{ $autodetect := dict "firstFound" true }}
+{{ $_ := set $calicoNetwork "nodeAddressAutodetectionV4" $autodetect }}
+{{ end }}
+{{ end }}
+{{ if empty .Values.installation.calicoNetwork.nodeAddressAutodetectionV6 }}
+{{ if not (empty .Values.global.clusterCIDRv6) }}
+{{ $calicoNetwork := get .Values.installation "calicoNetwork" }}
+{{ $autodetect := dict "firstFound" true }}
+{{ $_ := set $calicoNetwork "nodeAddressAutodetectionV6" $autodetect }}
+{{ end }}
+{{ end }}
+{{ end }}
+
apiVersion: operator.tigera.io/v1
kind: Installation

View File

@ -1,5 +1,5 @@
url: https://github.com/projectcalico/calico/releases/download/v3.29.1/tigera-operator-v3.29.1.tgz
packageVersion: 00
packageVersion: 01
additionalCharts:
- workingDir: charts-crd
crdOptions: