mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-01 07:47:56 +00:00
Add a missing ${PROJECT}
This commit is contained in:
parent
c4d040c720
commit
dea86ed926
@ -113,13 +113,14 @@ function prepare-upgrade() {
|
|||||||
#
|
#
|
||||||
# Assumed vars:
|
# Assumed vars:
|
||||||
# MASTER_NAME
|
# MASTER_NAME
|
||||||
|
# PROJECT
|
||||||
# ZONE
|
# ZONE
|
||||||
#
|
#
|
||||||
# Args:
|
# Args:
|
||||||
# $1 env key to use
|
# $1 env key to use
|
||||||
function get-env-val() {
|
function get-env-val() {
|
||||||
# TODO(mbforbes): Make this more reliable with retries.
|
# TODO(mbforbes): Make this more reliable with retries.
|
||||||
gcloud compute ssh --zone ${ZONE} ${MASTER_NAME} --command \
|
gcloud compute --project ${PROJECT} ssh --zone ${ZONE} ${MASTER_NAME} --command \
|
||||||
"curl --fail --silent -H 'Metadata-Flavor: Google' \
|
"curl --fail --silent -H 'Metadata-Flavor: Google' \
|
||||||
'http://metadata/computeMetadata/v1/instance/attributes/kube-env'" 2>/dev/null \
|
'http://metadata/computeMetadata/v1/instance/attributes/kube-env'" 2>/dev/null \
|
||||||
| grep ${1} | cut -d : -f 2 | cut -d \' -f 2
|
| grep ${1} | cut -d : -f 2 | cut -d \' -f 2
|
||||||
|
Loading…
Reference in New Issue
Block a user