Merge pull request #253 from rbrtbnfgl/calico-ipv6

Updated calico chart to support IPv6 only setup
pull/256/head
Roberto Bonafiglia 2022-05-10 09:05:05 +02:00 committed by GitHub
commit e7c0fed30f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 2 deletions

View File

@ -1,6 +1,6 @@
--- charts-original/templates/crs/custom-resources.yaml --- charts-original/templates/crs/custom-resources.yaml
+++ charts/templates/crs/custom-resources.yaml +++ charts/templates/crs/custom-resources.yaml
@@ -6,6 +6,27 @@ @@ -6,6 +6,30 @@
{{ $secrets = append $secrets $item }} {{ $secrets = append $secrets $item }}
{{ end }} {{ end }}
{{ $_ := set $installSpec "imagePullSecrets" $secrets }} {{ $_ := set $installSpec "imagePullSecrets" $secrets }}
@ -16,11 +16,14 @@
+*/}} +*/}}
+{{ if not (empty .Values.global.clusterCIDRv6) }} +{{ if not (empty .Values.global.clusterCIDRv6) }}
+{{ $myIP6Dict := dict "natOutgoing" "Enabled" "cidr" .Values.global.clusterCIDRv6 }} +{{ $myIP6Dict := dict "natOutgoing" "Enabled" "cidr" .Values.global.clusterCIDRv6 }}
+{{ $finalIpPoolList := list $myIP6Dict }}
+{{ if not (empty .Values.global.clusterCIDRv4) }}
+{{ $allIpPools := get .Values.installation.calicoNetwork "ipPools" }} +{{ $allIpPools := get .Values.installation.calicoNetwork "ipPools" }}
+{{ range $allIpPools }} +{{ range $allIpPools }}
+{{ $_ := set . "encapsulation" "None" }} +{{ $_ := set . "encapsulation" "None" }}
+{{ end }} +{{ end }}
+{{ $finalIpPoolList := append $allIpPools $myIP6Dict }} +{{ $finalIpPoolList := append $allIpPools $myIP6Dict }}
+{ end }}
+{{ $calicoNetwork := get .Values.installation "calicoNetwork" }} +{{ $calicoNetwork := get .Values.installation "calicoNetwork" }}
+{{ $_ := set $calicoNetwork "ipPools" $finalIpPoolList }} +{{ $_ := set $calicoNetwork "ipPools" $finalIpPoolList }}
+{{ $_ := set $calicoNetwork "bgp" "Enabled" }} +{{ $_ := set $calicoNetwork "bgp" "Enabled" }}

View File

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