Skip to content

Commit dc410fa

Browse files
committed
Add K8s 1.31 to CI by pinning kops commit
1 parent e6dae61 commit dc410fa

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

hack/e2e/config.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ OUTPOST_INSTANCE_TYPE=${OUTPOST_INSTANCE_TYPE:-${INSTANCE_TYPE}}
3535
# kops: must include patch version (e.g. 1.19.1)
3636
# eksctl: mustn't include patch version (e.g. 1.19)
3737
# NOTE: Keep KOPS at v1.29.x until ELB usage bug fixed
38-
K8S_VERSION_KOPS=${K8S_VERSION_KOPS:-1.29.6}
38+
K8S_VERSION_KOPS=${K8S_VERSION_KOPS:-1.31.1}
3939
K8S_VERSION_EKSCTL=${K8S_VERSION_EKSCTL:-1.31}
4040

4141
EBS_INSTALL_SNAPSHOT=${EBS_INSTALL_SNAPSHOT:-"true"}

hack/e2e/kops/kops.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ function kops_create_cluster() {
3232
KOPS_PATCH_FILE=${10}
3333
KOPS_PATCH_NODE_FILE=${11}
3434
KOPS_STATE_FILE=${12}
35+
declare -x KOPS_TOO_NEW_VERSION=true
3536

3637
if kops_cluster_exists "${CLUSTER_NAME}" "${KOPS_BIN}" "${KOPS_STATE_FILE}"; then
3738
loudecho "Replacing cluster $CLUSTER_NAME with $CLUSTER_FILE"
@@ -99,7 +100,6 @@ function kops_patch_cluster_file() {
99100
KOPS_PATCH_FILE=${2} # input must be yaml
100101
KIND=${3} # must be either Cluster or InstanceGroup
101102
ROLE=${4} # must be either Master or Node
102-
103103
loudecho "Patching cluster $CLUSTER_NAME with $KOPS_PATCH_FILE"
104104

105105
# Temporary intermediate files for patching, don't mutate CLUSTER_FILE until

hack/tools/install.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ GOMPLATE_VERSION="v4.1.0"
3333
# https://github.com/helm/helm
3434
HELM_VERSION="v3.16.2"
3535
# https://github.com/kubernetes/kops
36-
# NOTE: Keep at v1.29.0 until ELB usage bug fixed
37-
KOPS_VERSION="v1.29.0"
36+
# NOTE: We pin kops to a commit instead of a release to support newer versions of k8s earlier
37+
KOPS_COMMIT="aaa35cc5304f9b191ca9828b552e62bddc5b263a"
3838
# https://pkg.go.dev/sigs.k8s.io/kubetest2?tab=versions
3939
KUBETEST2_VERSION="v0.0.0-20240905095256-f6e8664cd2b1"
4040
# https://github.com/golang/mock
@@ -153,9 +153,11 @@ function install_helm() {
153153
}
154154

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

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

161163
function install_kubetest2() {

0 commit comments

Comments
 (0)