Skip to content

Commit

Permalink
install.sh: waiting for deleted kube-ovn-pinger to disapper (#4096)
Browse files Browse the repository at this point in the history
Signed-off-by: zhangzujian <zhangzujian.7@gmail.com>
  • Loading branch information
zhangzujian committed May 29, 2024
1 parent cde29e9 commit 64d1e1c
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions dist/images/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4731,8 +4731,16 @@ for ns in $(kubectl get ns --no-headers -o custom-columns=NAME:.metadata.name);
done

kubectl rollout status deployment/coredns -n kube-system --timeout 300s
kubectl rollout status daemonset/kube-ovn-pinger -n kube-system --timeout 300s
kubectl wait pod --for=condition=Ready -l app=kube-ovn-pinger -n kube-system --timeout 300s
while true; do
pods=(`kubectl get pod -n kube-system -l app=kube-ovn-pinger --template '{{range .items}}{{if .metadata.deletionTimestamp}}{{.metadata.name}}{{"\n"}}{{end}}{{end}}'`)
if [ ${#pods[@]} -eq 0 ]; then
break
fi
echo "Waiting for ${pods[@]} to be deleted..."
sleep 1
done
kubectl rollout status daemonset/kube-ovn-pinger -n kube-system --timeout 120s
kubectl wait pod --for=condition=Ready -l app=kube-ovn-pinger -n kube-system --timeout 120s
echo "-------------------------------"
echo ""

Expand Down

0 comments on commit 64d1e1c

Please sign in to comment.