Skip to content

Commit 89d3780

Browse files
committed
cleanup helm chart
Signed-off-by: chaosi-zju <[email protected]>
1 parent 9928020 commit 89d3780

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

charts/karmada/templates/post-install-job.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,13 @@ spec:
5050
- |
5151
bash <<'EOF'
5252
set -ex
53+
54+
# The `post-install hook job` may be applied before all karmada components are ready that rely on `static-resource job` and `hook-job secret`.
55+
# So, we have to postpone the deletion of the `static-resource job` and `hook-job secret` until all karmada components are up and running.
56+
while [[ $(kubectl get pods -n {{ $namespace }} --field-selector=status.phase!=Running,status.phase!=Succeeded -o jsonpath='{range .items[*]}{.metadata.name}{"\n"}{end}' | wc -l) > 0 ]]; do
57+
echo "waiting for all pods of karmada control plane ready..."; sleep 1;
58+
done
59+
5360
kubectl delete job {{ $name }}-static-resource -n {{ $namespace }}
5461
kubectl delete secret {{ $name }}-hook-job -n {{ $namespace }}
5562
EOF

charts/karmada/values.yaml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -511,10 +511,7 @@ metricsAdapter:
511511
registry: docker.io
512512
repository: karmada/karmada-metrics-adapter
513513
tag: *karmadaImageVersion
514-
## Specify a imagePullPolicy
515-
## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
516-
##
517-
pullPolicy: Always
514+
pullPolicy: *karmadaImagePullPolicy
518515
## Optionally specify an array of imagePullSecrets.
519516
## Secrets must be manually created in the namespace.
520517
## Example:

0 commit comments

Comments
 (0)