From 0105d03d94185b99daabc74f9b4ecb9bbf2e5715 Mon Sep 17 00:00:00 2001 From: Jonathan Innis Date: Thu, 15 Feb 2024 17:12:40 -0800 Subject: [PATCH] ci: Pin to the latest patch version of 1.25.x in toolchain (#5672) --- hack/toolchain.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/hack/toolchain.sh b/hack/toolchain.sh index af85963a97ff..0ebbd86d5207 100755 --- a/hack/toolchain.sh +++ b/hack/toolchain.sh @@ -35,6 +35,15 @@ kubebuilder() { arch=$(go env GOARCH) ln -sf $(setup-envtest use -p path "${K8S_VERSION}" --arch="${arch}" --bin-dir="${KUBEBUILDER_ASSETS}")/* ${KUBEBUILDER_ASSETS} find $KUBEBUILDER_ASSETS + + # Install latest binaries for 1.25.x (contains CEL fix) + if [[ "${K8S_VERSION}" = "1.25.x" ]] && [[ "$OSTYPE" == "linux"* ]]; then + for binary in 'kube-apiserver' 'kubectl'; do + rm $KUBEBUILDER_ASSETS/$binary + wget -P $KUBEBUILDER_ASSETS dl.k8s.io/v1.25.16/bin/linux/${arch}/${binary} + chmod +x $KUBEBUILDER_ASSETS/$binary + done + fi } main "$@"