Skip to content

Commit

Permalink
Add K8s 1.31 to CI by pinning kops commit
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewSirenko committed Oct 11, 2024
1 parent 8cae810 commit f46e261
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
3 changes: 1 addition & 2 deletions hack/e2e/config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,8 @@ OUTPOST_ARN=${OUTPOST_ARN:-}
OUTPOST_INSTANCE_TYPE=${OUTPOST_INSTANCE_TYPE:-${INSTANCE_TYPE}}

# kops: must include patch version (e.g. 1.19.1)
# eksctl: mustn't include patch version (e.g. 1.19)
# NOTE: Keep KOPS at v1.29.x until ELB usage bug fixed
K8S_VERSION_KOPS=${K8S_VERSION_KOPS:-1.29.6}
K8S_VERSION_KOPS=${K8S_VERSION_KOPS:-1.31.1}
K8S_VERSION_EKSCTL=${K8S_VERSION_EKSCTL:-1.31}

EBS_INSTALL_SNAPSHOT=${EBS_INSTALL_SNAPSHOT:-"true"}
Expand Down
2 changes: 2 additions & 0 deletions hack/e2e/kops/kops.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@

set -euo pipefail

export KOPS_RUN_TOO_NEW_VERSION=true

function kops_create_cluster() {
CLUSTER_NAME=${1}
KOPS_BIN=${2}
Expand Down
2 changes: 2 additions & 0 deletions hack/prow-e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ export CLUSTER_NAME="e2e-${BUILD_ID:-${RANDOM}}.k8s.local"
export KOPS_BUCKET=${KOPS_BUCKET:-"k8s-kops-csi-shared-e2e"}
# Always use us-west-2 in CI, no matter where the local client is
export AWS_REGION=us-west-2
# Allow attempting using newer versions of K8s before kops releases catch up
export KOPS_RUN_TOO_NEW_VERSION=true

make cluster/create &
PIDS[1]=$!
Expand Down
8 changes: 5 additions & 3 deletions hack/tools/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ GOMPLATE_VERSION="v4.1.0"
# https://github.com/helm/helm
HELM_VERSION="v3.15.4"
# https://github.com/kubernetes/kops
# NOTE: Keep at v1.29.0 until ELB usage bug fixed
KOPS_VERSION="v1.29.0"
# NOTE: We pin kops to a commit instead of a release to support newer versions of k8s earlier
KOPS_COMMIT="3a8da3d7fc1d632ef5ffe4a6ef7e5e9fc048e0c7"
# https://pkg.go.dev/sigs.k8s.io/kubetest2?tab=versions
KUBETEST2_VERSION="v0.0.0-20240703180642-53f3d216ad9f"
# https://github.com/golang/mock
Expand Down Expand Up @@ -153,9 +153,11 @@ function install_helm() {
}

function install_kops() {
# Build from source so we can test latest Kubernetes version earlier.
INSTALL_PATH="${1}"

install_binary "${INSTALL_PATH}" "https://github.com/kubernetes/kops/releases/download/${KOPS_VERSION}/kops-${OS}-${ARCH}" "kops"
# Lower max processes to avoid oom-killed
GOMAXPROCS=1 install_go "${INSTALL_PATH}" "k8s.io/kops/cmd/kops@${KOPS_COMMIT}"
}

function install_kubetest2() {
Expand Down

0 comments on commit f46e261

Please sign in to comment.