mirror of https://github.com/kubernetes/kops.git
Add support for setting latest k8s in ab scenario
This commit is contained in:
parent
9b4f5b6a4a
commit
d3416aac60
|
@ -17,11 +17,18 @@
|
|||
REPO_ROOT=$(git rev-parse --show-toplevel);
|
||||
source "${REPO_ROOT}"/tests/e2e/scenarios/lib/common.sh
|
||||
|
||||
if [ -z "$KOPS_VERSION_A" ] || [ -z "$K8S_VERSION_A" ] || [ -z "$KOPS_VERSION_B" ] || [ -z "$K8S_VERSION_B" ]; then
|
||||
if [ -z "${KOPS_VERSION_A-}" ] || [ -z "${K8S_VERSION_A-}" ] || [ -z "${KOPS_VERSION_B-}" ] || [ -z "${K8S_VERSION_B-}" ]; then
|
||||
>&2 echo "must set all of KOPS_VERSION_A, K8S_VERSION_A, KOPS_VERSION_B, K8S_VERSION_B env vars"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "$K8S_VERSION_A" == "latest" ]]; then
|
||||
K8S_VERSION_A=$(curl https://storage.googleapis.com/kubernetes-release/release/latest.txt)
|
||||
fi
|
||||
if [[ "$K8S_VERSION_B" == "latest" ]]; then
|
||||
K8S_VERSION_B=$(curl https://storage.googleapis.com/kubernetes-release/release/latest.txt)
|
||||
fi
|
||||
|
||||
export KOPS_BASE_URL
|
||||
KOPS_BASE_URL=$(kops-base-from-marker "${KOPS_VERSION_A}")
|
||||
KOPS_A=$(kops-download-from-base)
|
||||
|
|
Loading…
Reference in New Issue