Skip to content

Commit

Permalink
Merge commit '55b003d640b05d881db5d2e1e0ec4bfaeeaa3466' into common-e…
Browse files Browse the repository at this point in the history
…xample
  • Loading branch information
kvaps committed Dec 24, 2020
2 parents 2db4645 + 55b003d commit c14e1af
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions release-tools/prow.sh
Original file line number Diff line number Diff line change
Expand Up @@ -801,11 +801,12 @@ install_snapshot_controller() {
fi
cnt=0
expected_running_pods=$(curl https://raw.githubusercontent.com/kubernetes-csi/external-snapshotter/"${CSI_SNAPSHOTTER_VERSION}"/deploy/kubernetes/snapshot-controller/setup-snapshot-controller.yaml | grep replicas | cut -d ':' -f 2-)
while [ "$(kubectl get pods -l app=snapshot-controller | grep 'Running' -c)" -lt "$expected_running_pods" ]; do
expected_running_pods=$(awk -F '[: ]+' '$1 == "" && $2 == "replicas" {print $3; exit}' "${CONTROLLER_DIR}/deploy/kubernetes/snapshot-controller/setup-snapshot-controller.yaml")
expected_namespace=$(awk -F '[: ]+' '$1 == "" && $2 == "namespace" {print $3; exit}' "${CONTROLLER_DIR}/deploy/kubernetes/snapshot-controller/setup-snapshot-controller.yaml")
while [ "$(kubectl get pods -n "$expected_namespace" -l app=snapshot-controller | grep 'Running' -c)" -lt "$expected_running_pods" ]; do
if [ $cnt -gt 30 ]; then
echo "snapshot-controller pod status:"
kubectl describe pods -l app=snapshot-controller
kubectl describe pods -n "$expected_namespace" -l app=snapshot-controller
echo >&2 "ERROR: snapshot controller not ready after over 5 min"
exit 1
fi
Expand Down

0 comments on commit c14e1af

Please sign in to comment.