mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 03:11:40 +00:00
Test startup: make staging bucket regional
Make GCS buckets created by the e2e tests regional. There are by default multi-regional in US location. The change is introduced to minimize GCS global cost. GCS new pricing changed since Oct 1, 2022. See https://cloud.google.com/storage/pricing-announce Signed-off-by: Arnaud Meukam <ameukam@gmail.com>
This commit is contained in:
parent
8db0d1a8e0
commit
9987e4635f
@ -257,13 +257,13 @@ function copy-to-staging() {
|
|||||||
function set-preferred-region() {
|
function set-preferred-region() {
|
||||||
case ${ZONE} in
|
case ${ZONE} in
|
||||||
asia-*)
|
asia-*)
|
||||||
PREFERRED_REGION=("asia" "us" "eu")
|
PREFERRED_REGION=("asia-northeast1" "us-central1" "europe-west6")
|
||||||
;;
|
;;
|
||||||
europe-*)
|
europe-*)
|
||||||
PREFERRED_REGION=("eu" "us" "asia")
|
PREFERRED_REGION=("europe-west6" "us-central1" "asia-northeast1")
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
PREFERRED_REGION=("us" "eu" "asia")
|
PREFERRED_REGION=("us-central1" "europe-west6" "asia-northeast1")
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@ -327,7 +327,7 @@ function upload-tars() {
|
|||||||
|
|
||||||
for region in "${PREFERRED_REGION[@]}"; do
|
for region in "${PREFERRED_REGION[@]}"; do
|
||||||
suffix="-${region}"
|
suffix="-${region}"
|
||||||
if [[ "${suffix}" == "-us" ]]; then
|
if [[ "${suffix}" == "-us-central1" ]]; then
|
||||||
suffix=""
|
suffix=""
|
||||||
fi
|
fi
|
||||||
local staging_bucket="gs://kubernetes-staging-${project_hash}${suffix}"
|
local staging_bucket="gs://kubernetes-staging-${project_hash}${suffix}"
|
||||||
|
Loading…
Reference in New Issue
Block a user