diff --git a/.github/workflows/e2e-tests.yaml b/.github/workflows/e2e-tests.yaml index 985e875..6217745 100644 --- a/.github/workflows/e2e-tests.yaml +++ b/.github/workflows/e2e-tests.yaml @@ -134,6 +134,7 @@ jobs: - name: Install tools run: | export ACTION=install_tools + export K8S_VERSION=${{ matrix.kubernetes-version }} tests/e2e-kubernetes/scripts/run.sh - name: Run Controller Tests run: | diff --git a/tests/e2e-kubernetes/scripts/run.sh b/tests/e2e-kubernetes/scripts/run.sh index 448aef9..22fb687 100755 --- a/tests/e2e-kubernetes/scripts/run.sh +++ b/tests/e2e-kubernetes/scripts/run.sh @@ -79,8 +79,8 @@ mkdir -p ${BIN_DIR} export PATH="$PATH:${BIN_DIR}" function kubectl_install() { - curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" - curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl.sha256" + curl -LO "https://dl.k8s.io/release/v$K8S_VERSION/bin/linux/amd64/kubectl" + curl -LO "https://dl.k8s.io/release/v$K8S_VERSION/bin/linux/amd64/kubectl.sha256" echo "$(cat kubectl.sha256) kubectl" | sha256sum --check sudo install -o root -g root -m 0755 kubectl ${KUBECTL_INSTALL_PATH}/kubectl }