mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 20:24:09 +00:00
Fix the scripts to optionally skip prompts and also return successfully no matter what.
This commit is contained in:
parent
1aa2b97792
commit
6fd376a04f
@ -24,6 +24,8 @@ source "${KUBE_ROOT}/cluster/common.sh"
|
||||
|
||||
NODE_INSTANCE_PREFIX="${INSTANCE_PREFIX}-minion"
|
||||
|
||||
KUBE_PROMPT_FOR_UPDATE=y
|
||||
|
||||
# Verify prereqs
|
||||
function verify-prereqs {
|
||||
local cmd
|
||||
@ -43,8 +45,11 @@ function verify-prereqs {
|
||||
fi
|
||||
done
|
||||
# update and install components as needed
|
||||
gcloud components update preview
|
||||
gcloud components update
|
||||
if [[ "${KUBE_PROMPT_FOR_UPDATE}" != "y" ]]; then
|
||||
gcloud_prompt="-q"
|
||||
fi
|
||||
gcloud ${gcloud_prompt:-} components update preview || true
|
||||
gcloud ${gcloud_prompt:-} components update || true
|
||||
}
|
||||
|
||||
# Create a temp dir that'll be deleted at the end of this bash session.
|
||||
|
Loading…
Reference in New Issue
Block a user