mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-17 07:03:31 +00:00
Merge pull request #25173 from ixdy/gcloud-grep-awk-cut
Automatic merge from submit-queue Use --format='value(name)' with gcloud instead of grep/awk/cut Fixing our fragile parsing of `gcloud` is getting old (#24746, #25159, maybe others?). Instead, let's just get the proper output out of `gcloud` in the first place.
This commit is contained in:
@@ -34,10 +34,7 @@ function fetch_output_tars() {
|
||||
}
|
||||
|
||||
function fetch_server_version_tars() {
|
||||
local -r msg=$(gcloud ${CMD_GROUP:-} container get-server-config --project=${PROJECT} --zone=${ZONE} | grep defaultClusterVersion)
|
||||
# msg will look like "defaultClusterVersion: 1.0.1". Strip
|
||||
# everything up to, including ": "
|
||||
local -r build_version="v${msg##*: }"
|
||||
local -r build_version="v$(gcloud ${CMD_GROUP:-} container get-server-config --project=${PROJECT} --zone=${ZONE} --format='value(defaultClusterVersion)')"
|
||||
fetch_tars_from_gcs "release" "${build_version}"
|
||||
unpack_binaries
|
||||
}
|
||||
|
Reference in New Issue
Block a user