Skip to content

Commit b29e04c

Browse files
authored
Merge pull request #5297 from richardcase/e2e_eks_changes
🐛 fix: e2e changes to remove v1.23
2 parents 969bfc4 + d004496 commit b29e04c

File tree

10 files changed

+18
-582
lines changed

10 files changed

+18
-582
lines changed

test/e2e/data/e2e_conf.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -180,9 +180,6 @@ variables:
180180
KUBERNETES_VERSION: "v1.29.9"
181181
KUBERNETES_VERSION_UPGRADE_TO: "v1.29.9"
182182
KUBERNETES_VERSION_UPGRADE_FROM: "v1.29.8"
183-
# Pre and post 1.23 Kubernetes versions are being used for CSI upgrade tests
184-
PRE_1_23_KUBERNETES_VERSION: "v1.22.17"
185-
POST_1_23_KUBERNETES_VERSION: "v1.23.15"
186183
CNI: "../../data/cni/calico.yaml"
187184
KUBETEST_CONFIGURATION: "../../data/kubetest/conformance.yaml"
188185
EVENT_BRIDGE_INSTANCE_STATE: "true"

test/e2e/data/e2e_eks_conf.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ images:
1616
- name: gcr.io/k8s-staging-cluster-api/capa-manager:e2e
1717
loadBehavior: mustLoad
1818

19-
## PLEASE KEEP THESE UP TO DATE WITH THE COMPONENTS
19+
## PLEASE KEEP THESE UP TO DATE WITH THE COMPONENTS
2020
- name: quay.io/jetstack/cert-manager-cainjector:v1.15.1
2121
loadBehavior: tryLoad
2222
- name: quay.io/jetstack/cert-manager-webhook:v1.15.1
@@ -118,6 +118,8 @@ providers:
118118
variables:
119119
KUBERNETES_VERSION: "v1.30.2"
120120
KUBERNETES_VERSION_MANAGEMENT: "v1.30.0" # Kind bootstrap
121+
UPGRADE_FROM_VERSION: "v1.30.0"
122+
UPGRADE_TO_VERSION: "v1.31.0"
121123
EXP_MACHINE_POOL: "true"
122124
EXP_CLUSTER_RESOURCE_SET: "true"
123125
EVENT_BRIDGE_INSTANCE_STATE: "true"

test/e2e/data/eks/cluster-template-eks-ipv6-cluster.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,6 @@ spec:
4545
- name: "vpc-cni"
4646
version: "${VPC_ADDON_VERSION}"
4747
conflictResolution: "overwrite"
48-
- name: "coredns"
49-
version: "${COREDNS_ADDON_VERSION}"
50-
conflictResolution: "overwrite"
5148
- name: "kube-proxy"
5249
version: "${KUBE_PROXY_ADDON_VERSION}"
5350
conflictResolution: "overwrite"

test/e2e/shared/defaults.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ const (
4343
CNIPath = "CNI"
4444
CNIResources = "CNI_RESOURCES"
4545
CNIAddonVersion = "VPC_ADDON_VERSION"
46-
CorednsAddonVersion = "COREDNS_ADDON_VERSION"
47-
CorednsAddonConfiguration = "COREDNS_ADDON_CONFIGURATION"
4846
GcWorkloadPath = "GC_WORKLOAD"
4947
KubeproxyAddonVersion = "KUBE_PROXY_ADDON_VERSION"
5048
AwsNodeMachineType = "AWS_NODE_MACHINE_TYPE"
@@ -66,11 +64,11 @@ const (
6664
StorageClassOutTreeZoneLabel = "topology.ebs.csi.aws.com/zone"
6765
GPUFlavor = "gpu"
6866
InstanceVcpu = "AWS_MACHINE_TYPE_VCPU_USAGE"
69-
PreCSIKubernetesVer = "PRE_1_23_KUBERNETES_VERSION"
70-
PostCSIKubernetesVer = "POST_1_23_KUBERNETES_VERSION"
7167
EFSSupport = "efs-support"
7268
IntreeCloudProvider = "intree-cloud-provider"
7369
MultiTenancy = "MULTI_TENANCY_"
70+
EksUpgradeFromVersion = "UPGRADE_FROM_VERSION"
71+
EksUpgradeToVersion = "UPGRADE_TO_VERSION"
7472
)
7573

7674
// ResourceQuotaFilePath is the path to the file that contains the resource usage.

test/e2e/suites/managed/eks_ipv6_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ var _ = ginkgo.Describe("[managed] [general] [ipv6] EKS cluster tests", func() {
5151
Expect(e2eCtx.E2EConfig).ToNot(BeNil(), "Invalid argument. e2eConfig can't be nil when calling %s spec", specName)
5252
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubernetesVersion))
5353
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CNIAddonVersion))
54-
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CorednsAddonVersion))
5554
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubeproxyAddonVersion))
5655

5756
ctx = context.TODO()

test/e2e/suites/managed/eks_legacy_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ var _ = ginkgo.Describe("[managed] [legacy] EKS cluster tests - single kind", fu
5050
Expect(e2eCtx.E2EConfig).ToNot(BeNil(), "Invalid argument. e2eConfig can't be nil when calling %s spec", specName)
5151
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubernetesVersion))
5252
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CNIAddonVersion))
53-
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CorednsAddonVersion))
5453
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubeproxyAddonVersion))
5554

5655
ctx = context.TODO()
@@ -71,7 +70,7 @@ var _ = ginkgo.Describe("[managed] [legacy] EKS cluster tests - single kind", fu
7170
Namespace: namespace,
7271
ClusterName: clusterName,
7372
Flavour: EKSControlPlaneOnlyLegacyFlavor,
74-
ControlPlaneMachineCount: 1, //NOTE: this cannot be zero as clusterctl returns an error
73+
ControlPlaneMachineCount: 1, // NOTE: this cannot be zero as clusterctl returns an error
7574
WorkerMachineCount: 0,
7675
}
7776
})

test/e2e/suites/managed/eks_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ var _ = ginkgo.Describe("[managed] [general] EKS cluster tests", func() {
5050
Expect(e2eCtx.E2EConfig).ToNot(BeNil(), "Invalid argument. e2eConfig can't be nil when calling %s spec", specName)
5151
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubernetesVersion))
5252
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CNIAddonVersion))
53-
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.CorednsAddonVersion))
5453

5554
ctx = context.TODO()
5655
namespace = shared.SetupSpecNamespace(ctx, specName, e2eCtx)
@@ -70,7 +69,7 @@ var _ = ginkgo.Describe("[managed] [general] EKS cluster tests", func() {
7069
Namespace: namespace,
7170
ClusterName: clusterName,
7271
Flavour: EKSControlPlaneOnlyWithAddonFlavor,
73-
ControlPlaneMachineCount: 1, //NOTE: this cannot be zero as clusterctl returns an error
72+
ControlPlaneMachineCount: 1, // NOTE: this cannot be zero as clusterctl returns an error
7473
WorkerMachineCount: 0,
7574
}
7675
})

test/e2e/suites/managed/upgrade_test.go

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,27 +35,29 @@ import (
3535

3636
// EKS cluster upgrade tests.
3737
var _ = ginkgo.Describe("EKS Cluster upgrade test", func() {
38-
const (
39-
initialVersion = "v1.23.6"
40-
upgradeToVersion = "v1.24.4"
41-
)
4238
var (
43-
namespace *corev1.Namespace
44-
ctx context.Context
45-
specName = "eks-upgrade"
46-
clusterName string
39+
namespace *corev1.Namespace
40+
ctx context.Context
41+
specName = "eks-upgrade"
42+
clusterName string
43+
initialVersion string
44+
upgradeToVersion string
4745
)
4846

4947
shared.ConditionalIt(runUpgradeTests, "[managed] [upgrade] should create a cluster and upgrade the kubernetes version", func() {
5048
ginkgo.By("should have a valid test configuration")
5149
Expect(e2eCtx.Environment.BootstrapClusterProxy).ToNot(BeNil(), "Invalid argument. BootstrapClusterProxy can't be nil")
5250
Expect(e2eCtx.E2EConfig).ToNot(BeNil(), "Invalid argument. e2eConfig can't be nil when calling %s spec", specName)
53-
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.KubernetesVersion))
51+
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.EksUpgradeFromVersion))
52+
Expect(e2eCtx.E2EConfig.Variables).To(HaveKey(shared.EksUpgradeToVersion))
5453

5554
ctx = context.TODO()
5655
namespace = shared.SetupSpecNamespace(ctx, specName, e2eCtx)
5756
clusterName = fmt.Sprintf("%s-%s", specName, util.RandomString(6))
5857

58+
initialVersion = e2eCtx.E2EConfig.GetVariable(shared.EksUpgradeFromVersion)
59+
upgradeToVersion = e2eCtx.E2EConfig.GetVariable(shared.EksUpgradeToVersion)
60+
5961
ginkgo.By("default iam role should exist")
6062
VerifyRoleExistsAndOwned(ekscontrolplanev1.DefaultEKSControlPlaneRole, clusterName, false, e2eCtx.BootstrapUserAWSSession)
6163

0 commit comments

Comments
 (0)