From 6946379ae5a80707ff1759733fde8fadb9b566b9 Mon Sep 17 00:00:00 2001 From: Stefan Reimer Date: Mon, 20 Nov 2023 20:44:50 +0000 Subject: [PATCH] More cleanup --- admin/pre-upgrade.sh | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 admin/pre-upgrade.sh diff --git a/admin/pre-upgrade.sh b/admin/pre-upgrade.sh deleted file mode 100644 index 86e35193..00000000 --- a/admin/pre-upgrade.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash - -# get current values, argo app over cm -get_kubezero_values - -# tumble new config through migrate.py -migrate_argo_values.py < "$WORKDIR"/kubezero-values.yaml > "$WORKDIR"/new-kubezero-values.yaml - -# Update kubezero-values CM -kubectl get cm -n kube-system kubezero-values -o=yaml | \ - yq e '.data."values.yaml" |= load_str("/tmp/kubezero/new-kubezero-values.yaml")' | \ - kubectl replace -f - - -# update argo app -kubectl get application kubezero -n argocd -o yaml | \ - kubezero_chart_version=$(yq .version /charts/kubezero/Chart.yaml) \ - yq '.spec.source.helm.values |= load_str("/tmp/kubezero/new-kubezero-values.yaml") | .spec.source.targetRevision = strenv(kubezero_chart_version)' | \ - kubectl apply -f - - -# finally remove annotation to allow argo to sync again -kubectl patch app kubezero -n argocd --type json -p='[{"op": "remove", "path": "/metadata/annotations"}]'