Skip to content

Commit

Permalink
prow.sh: debug failing KinD cluster creation
Browse files Browse the repository at this point in the history
When KinD fails in a Prow job, we need additional information to
understand why it failed.
  • Loading branch information
pohly committed Apr 9, 2019
1 parent 9b0d9cd commit 546d550
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion prow.sh
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,17 @@ $(list_gates "$gates")
featureGates:
$(list_gates "$gates")
EOF
run kind create cluster --name csi-prow --config "${CSI_PROW_WORK}/kind-config.yaml" --wait 5m --image "$image" || die "'kind create cluster' failed"
info "kind-config.yaml:"
cat "${CSI_PROW_WORK}/kind-config.yaml"
if ! run kind create cluster --name csi-prow --config "${CSI_PROW_WORK}/kind-config.yaml" --wait 5m --image "$image"; then
warn "Cluster creation failed. Will try again with higher verbosity."
info "Available Docker images:"
docker image ls
if ! run kind --loglevel debug create cluster --retain --name csi-prow --config "${CSI_PROW_WORK}/kind-config.yaml" --wait 5m --image "$image"; then
run kind export logs --name csi-prow "$ARTIFACTS/kind-cluster"
die "Cluster creation failed again, giving up. See the 'kind-cluster' artifact directory for additional logs."
fi
fi
KUBECONFIG="$(kind get kubeconfig-path --name=csi-prow)"
export KUBECONFIG
}
Expand Down

0 comments on commit 546d550

Please sign in to comment.