From e89e80057a0ad34cafeac2b8bd5157ec19284bf5 Mon Sep 17 00:00:00 2001 From: Furkat Gofurov Date: Wed, 12 Apr 2023 19:19:04 +0300 Subject: [PATCH 1/3] Use k8s v1.27.0 in CAPD and tests Signed-off by: Furkat Gofurov (furkat.gofurov@suse.com) (cherry picked from commit fbf2406a2696a98f7a945aa20585135318327f24) --- test/e2e/clusterctl_upgrade_test.go | 4 ++-- test/e2e/config/docker.yaml | 12 ++++++------ test/framework/bootstrap/kind_provider.go | 2 +- .../infrastructure/docker/examples/machine-pool.yaml | 4 ++-- .../docker/examples/simple-cluster-ipv6.yaml | 4 ++-- .../docker/examples/simple-cluster-without-kcp.yaml | 4 ++-- .../docker/examples/simple-cluster.yaml | 4 ++-- .../infrastructure/docker/internal/docker/machine.go | 2 +- 8 files changed, 18 insertions(+), 18 deletions(-) diff --git a/test/e2e/clusterctl_upgrade_test.go b/test/e2e/clusterctl_upgrade_test.go index 4a380550fd36..8acb157b381c 100644 --- a/test/e2e/clusterctl_upgrade_test.go +++ b/test/e2e/clusterctl_upgrade_test.go @@ -211,7 +211,7 @@ var _ = Describe("When testing clusterctl upgrades (v1.3=>current)", func() { SkipCleanup: skipCleanup, InitWithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.3.5/clusterctl-{OS}-{ARCH}", InitWithProvidersContract: "v1beta1", - InitWithKubernetesVersion: "v1.26.0", + InitWithKubernetesVersion: "v1.27.0", MgmtFlavor: "topology", WorkloadFlavor: "", // This check ensures that ownerReference apiVersions are updated for all types after the upgrade. @@ -239,7 +239,7 @@ var _ = Describe("When testing clusterctl upgrades using ClusterClass (v1.3=>cur SkipCleanup: skipCleanup, InitWithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.3.5/clusterctl-{OS}-{ARCH}", InitWithProvidersContract: "v1beta1", - InitWithKubernetesVersion: "v1.26.0", + InitWithKubernetesVersion: "v1.27.0", MgmtFlavor: "topology", WorkloadFlavor: "topology", // This check ensures that ownerReference apiVersions are updated for all types after the upgrade. diff --git a/test/e2e/config/docker.yaml b/test/e2e/config/docker.yaml index c6adf28202e0..86fb80db70e2 100644 --- a/test/e2e/config/docker.yaml +++ b/test/e2e/config/docker.yaml @@ -291,12 +291,12 @@ variables: # allowing the same e2e config file to be re-used in different Prow jobs e.g. each one with a K8s version permutation. # The following Kubernetes versions should be the latest versions with already published kindest/node images. # This avoids building node images in the default case which improves the test duration significantly. - KUBERNETES_VERSION_MANAGEMENT: "v1.26.0" - KUBERNETES_VERSION: "v1.26.0" - KUBERNETES_VERSION_UPGRADE_FROM: "v1.25.3" - KUBERNETES_VERSION_UPGRADE_TO: "v1.26.0" - ETCD_VERSION_UPGRADE_TO: "3.5.6-0" - COREDNS_VERSION_UPGRADE_TO: "v1.9.3" + KUBERNETES_VERSION_MANAGEMENT: "v1.27.0" + KUBERNETES_VERSION: "v1.27.0" + KUBERNETES_VERSION_UPGRADE_FROM: "v1.26.3" + KUBERNETES_VERSION_UPGRADE_TO: "v1.27.0" + ETCD_VERSION_UPGRADE_TO: "3.5.7-0" + COREDNS_VERSION_UPGRADE_TO: "v1.10.1" DOCKER_SERVICE_DOMAIN: "cluster.local" IP_FAMILY: "IPv4" DOCKER_SERVICE_CIDRS: "10.128.0.0/12" diff --git a/test/framework/bootstrap/kind_provider.go b/test/framework/bootstrap/kind_provider.go index eb13eeefb050..a71580e1afc9 100644 --- a/test/framework/bootstrap/kind_provider.go +++ b/test/framework/bootstrap/kind_provider.go @@ -37,7 +37,7 @@ const ( DefaultNodeImageRepository = "kindest/node" // DefaultNodeImageVersion is the default Kubernetes version to be used for creating a kind cluster. - DefaultNodeImageVersion = "v1.26.0" + DefaultNodeImageVersion = "v1.27.0" ) // KindClusterOption is a NewKindClusterProvider option. diff --git a/test/infrastructure/docker/examples/machine-pool.yaml b/test/infrastructure/docker/examples/machine-pool.yaml index 4bade93285b9..add1af85a1db 100644 --- a/test/infrastructure/docker/examples/machine-pool.yaml +++ b/test/infrastructure/docker/examples/machine-pool.yaml @@ -35,7 +35,7 @@ metadata: namespace: default spec: replicas: 1 - version: v1.26.0 + version: v1.27.0 machineTemplate: infrastructureRef: apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 @@ -80,7 +80,7 @@ spec: replicas: 2 template: spec: - version: v1.26.0 + version: v1.27.0 clusterName: my-cluster bootstrap: configRef: diff --git a/test/infrastructure/docker/examples/simple-cluster-ipv6.yaml b/test/infrastructure/docker/examples/simple-cluster-ipv6.yaml index 95cda19c039e..dbaea5b219ac 100644 --- a/test/infrastructure/docker/examples/simple-cluster-ipv6.yaml +++ b/test/infrastructure/docker/examples/simple-cluster-ipv6.yaml @@ -35,7 +35,7 @@ metadata: namespace: default spec: replicas: 1 - version: v1.26.0 + version: v1.27.0 machineTemplate: infrastructureRef: apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 @@ -90,7 +90,7 @@ spec: cluster.x-k8s.io/cluster-name: my-cluster template: spec: - version: v1.26.0 + version: v1.27.0 clusterName: my-cluster bootstrap: configRef: diff --git a/test/infrastructure/docker/examples/simple-cluster-without-kcp.yaml b/test/infrastructure/docker/examples/simple-cluster-without-kcp.yaml index 10ca83cdc472..7c1d90a8b1c1 100644 --- a/test/infrastructure/docker/examples/simple-cluster-without-kcp.yaml +++ b/test/infrastructure/docker/examples/simple-cluster-without-kcp.yaml @@ -32,7 +32,7 @@ metadata: name: controlplane-0 namespace: default spec: - version: v1.26.0 + version: v1.27.0 clusterName: my-cluster bootstrap: configRef: @@ -80,7 +80,7 @@ spec: cluster.x-k8s.io/cluster-name: my-cluster template: spec: - version: v1.26.0 + version: v1.27.0 clusterName: my-cluster bootstrap: configRef: diff --git a/test/infrastructure/docker/examples/simple-cluster.yaml b/test/infrastructure/docker/examples/simple-cluster.yaml index 38db43941beb..5daf6ddf49d1 100644 --- a/test/infrastructure/docker/examples/simple-cluster.yaml +++ b/test/infrastructure/docker/examples/simple-cluster.yaml @@ -35,7 +35,7 @@ metadata: namespace: default spec: replicas: 1 - version: v1.26.0 + version: v1.27.0 machineTemplate: infrastructureRef: apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 @@ -83,7 +83,7 @@ spec: cluster.x-k8s.io/cluster-name: my-cluster template: spec: - version: v1.26.0 + version: v1.27.0 clusterName: my-cluster bootstrap: configRef: diff --git a/test/infrastructure/docker/internal/docker/machine.go b/test/infrastructure/docker/internal/docker/machine.go index 054483264a9d..6a220d1aa302 100644 --- a/test/infrastructure/docker/internal/docker/machine.go +++ b/test/infrastructure/docker/internal/docker/machine.go @@ -50,7 +50,7 @@ import ( const ( defaultImageName = "kindest/node" - defaultImageTag = "v1.26.0" + defaultImageTag = "v1.27.0" ) type nodeCreator interface { From f944850b203e3fdc11cb4d1c2752a4dca1446c1d Mon Sep 17 00:00:00 2001 From: Furkat Gofurov Date: Wed, 12 Apr 2023 18:46:44 +0300 Subject: [PATCH 2/3] Bump k8s version to v1.27.0 in quickstart docs and Tiltfile Signed-off by: Furkat Gofurov (furkat.gofurov@suse.com) (cherry picked from commit 3f607b74019e808b961baadbffa464243f04d322) --- Tiltfile | 2 +- docs/book/src/developer/tilt.md | 2 +- docs/book/src/user/quick-start.md | 29 ++++++++++++++++++----------- 3 files changed, 20 insertions(+), 13 deletions(-) diff --git a/Tiltfile b/Tiltfile index 306b42cc6da4..1a57e8527c6e 100644 --- a/Tiltfile +++ b/Tiltfile @@ -4,7 +4,7 @@ envsubst_cmd = "./hack/tools/bin/envsubst" clusterctl_cmd = "./bin/clusterctl" kubectl_cmd = "kubectl" default_build_engine = "docker" -kubernetes_version = "v1.26.0" +kubernetes_version = "v1.27.0" if str(local("command -v " + kubectl_cmd + " || true", quiet = True)) == "": fail("Required command '" + kubectl_cmd + "' not found in PATH") diff --git a/docs/book/src/developer/tilt.md b/docs/book/src/developer/tilt.md index 0e71c43594ef..32690b2d95c6 100644 --- a/docs/book/src/developer/tilt.md +++ b/docs/book/src/developer/tilt.md @@ -325,7 +325,7 @@ Custom values for variable substitutions can be set using `kustomize_substitutio ```yaml kustomize_substitutions: NAMESPACE: default - KUBERNETES_VERSION: v1.26.0 + KUBERNETES_VERSION: v1.27.0 CONTROL_PLANE_MACHINE_COUNT: 1 WORKER_MACHINE_COUNT: 3 ``` diff --git a/docs/book/src/user/quick-start.md b/docs/book/src/user/quick-start.md index 716418040143..3549420d0295 100644 --- a/docs/book/src/user/quick-start.md +++ b/docs/book/src/user/quick-start.md @@ -1215,7 +1215,7 @@ The Docker provider is not designed for production use and is intended for devel ```bash clusterctl generate cluster capi-quickstart --flavor development \ - --kubernetes-version v1.26.0 \ + --kubernetes-version v1.27.0 \ --control-plane-machine-count=3 \ --worker-machine-count=3 \ > capi-quickstart.yaml @@ -1227,7 +1227,7 @@ clusterctl generate cluster capi-quickstart --flavor development \ ```bash export CLUSTER_NAME=kind export CLUSTER_NAMESPACE=vcluster -export KUBERNETES_VERSION=1.26.0 +export KUBERNETES_VERSION=1.27.0 export HELM_VALUES="service:\n type: NodePort" kubectl create namespace ${CLUSTER_NAMESPACE} @@ -1258,7 +1258,7 @@ clusterctl generate cluster capi-quickstart \ ```bash clusterctl generate cluster capi-quickstart \ - --kubernetes-version v1.26.0 \ + --kubernetes-version v1.27.0 \ --control-plane-machine-count=3 \ --worker-machine-count=3 \ > capi-quickstart.yaml @@ -1308,6 +1308,13 @@ You can also get an "at glance" view of the cluster and its resources by running clusterctl describe cluster capi-quickstart ``` +and see an output similar to this: + +```bash +NAME PHASE AGE VERSION +capi-quickstart Provisioned 8s v1.27.0 +``` + To verify the first control plane is up: ```bash @@ -1318,7 +1325,7 @@ You should see an output is similar to this: ```bash NAME CLUSTER INITIALIZED API SERVER AVAILABLE REPLICAS READY UPDATED UNAVAILABLE AGE VERSION -capi-quickstart-g2trk capi-quickstart true 3 3 3 4m7s v1.26.0 +capi-quickstart-g2trk capi-quickstart true 3 3 3 4m7s v1.27.0 ```