mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 12:15:52 +00:00
Fix getting last command result in kube-up
This commit is contained in:
parent
041d6bc775
commit
024322a651
@ -56,12 +56,15 @@ echo "... calling validate-cluster" >&2
|
||||
if [[ "${EXIT_ON_WEAK_ERROR}" == "true" ]]; then
|
||||
validate-cluster
|
||||
else
|
||||
if ! validate-cluster; then
|
||||
validate_result="$?"
|
||||
validate-cluster
|
||||
validate_result="$?"
|
||||
if [[ ${validate_result} != "0" ]]; then
|
||||
if [[ "${validate_result}" == "1" ]]; then
|
||||
exit 1
|
||||
elif [[ "${validate_result}" == "2" ]]; then
|
||||
echo "...ignoring non-fatal errors in validate-cluster" >&2
|
||||
else
|
||||
echo "Got unknown validate result: ${validate_result}"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user