Skip to content

Commit 9cd8b83

Browse files
authored
feat: apl operators cleanup (#1648)
1 parent c317521 commit 9cd8b83

File tree

1 file changed

+22
-2
lines changed

1 file changed

+22
-2
lines changed

upgrades/pre/upgrade-3-0-0.sh

+22-2
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,31 @@ kubectl annotate -n gitea secret/gitea-postgresql helm.sh/resource-policy='keep'
66
kubectl annotate -n gitea sts/gitea-postgresql helm.sh/resource-policy='keep' deprecated=true
77
kubectl annotate -n gitea svc/gitea-postgresql helm.sh/resource-policy='keep' deprecated=true
88

9-
109
if [[ $(helm status -n gatekeeper-system gatekeeper 2>/dev/null) ]]; then
1110
helm uninstall -n gatekeeper-system gatekeeper
1211
helm uninstall -n gatekeeper-system gatekeeper-artifacts
1312
helm uninstall -n gatekeeper-system gatekeeper-constraints
1413
helm uninstall -n gatekeeper-system opa-exporter-artifacts
1514
helm uninstall -n opa-exporter opa-exporter
16-
fi
15+
fi
16+
17+
if [[ $(kubectl get applications.argoproj.io gitea-operator-gitea-operator -n argocd 2>/dev/null) ]]; then
18+
kubectl delete applications.argoproj.io gitea-operator-gitea-operator -n argocd
19+
fi
20+
21+
if [[ $(helm status -n gitea-operator gitea-operator 2>/dev/null) ]]; then
22+
helm uninstall -n gitea-operator gitea-operator
23+
kubectl delete ns gitea-operator
24+
fi
25+
26+
if [[ $(helm status -n maintenance job-gitea-prepare 2>/dev/null) ]]; then
27+
helm uninstall -n maintenance job-gitea-prepare
28+
fi
29+
30+
if [[ $(helm status -n maintenance job-harbor 2>/dev/null) ]]; then
31+
helm uninstall -n maintenance job-harbor
32+
fi
33+
34+
if [[ $(helm status -n maintenance job-keycloak 2>/dev/null) ]]; then
35+
helm uninstall -n maintenance job-keycloak
36+
fi

0 commit comments

Comments
 (0)