fix: final fixes for cli tools of the v1.27 cycle

This commit is contained in:
Stefan Reimer 2024-03-22 12:21:55 +00:00
parent debc075018
commit 5e3d5d6839
2 changed files with 2 additions and 3 deletions

View File

@ -211,8 +211,7 @@ spec:
hostIPC: true hostIPC: true
hostPID: true hostPID: true
tolerations: tolerations:
- key: node-role.kubernetes.io/control-plane - operator: Exists
operator: Exists
effect: NoSchedule effect: NoSchedule
initContainers: initContainers:
- name: node-upgrade - name: node-upgrade

View File

@ -63,7 +63,7 @@ done
# Fix for legacy cert-manager CRDs to be upgraded # Fix for legacy cert-manager CRDs to be upgraded
for crd_name in certificaterequests.cert-manager.io certificates.cert-manager.io challenges.acme.cert-manager.io clusterissuers.cert-manager.io issuers.cert-manager.io orders.acme.cert-manager.io; do for crd_name in certificaterequests.cert-manager.io certificates.cert-manager.io challenges.acme.cert-manager.io clusterissuers.cert-manager.io issuers.cert-manager.io orders.acme.cert-manager.io; do
manager_index="$(kubectl get crd "${crd_name}" --show-managed-fields --output json | jq -r '.metadata.managedFields | map(.manager == "cainjector") | index(true)')" manager_index="$(kubectl get crd "${crd_name}" --show-managed-fields --output json | jq -r '.metadata.managedFields | map(.manager == "cert-manager-cainjector") | index(true)')"
[ "$manager_index" != "null" ] && kubectl patch crd "${crd_name}" --type=json -p="[{\"op\": \"remove\", \"path\": \"/metadata/managedFields/${manager_index}\"}]" [ "$manager_index" != "null" ] && kubectl patch crd "${crd_name}" --type=json -p="[{\"op\": \"remove\", \"path\": \"/metadata/managedFields/${manager_index}\"}]"
done done
# v1.27 # v1.27