Skip to content

Commit 29e991b

Browse files
committed
feat: update e2e test config and docs changes
This updates the kubernetes versions used in the e2e tests to use k8s versions that we AMIs for. It also marks some of the old CSI tests as pending and some upgrade tests as pending (which will be re-enabled at a later time). A few minor docs updates have been made as a result of review. Signed-off-by: Richard Case <[email protected]>
1 parent e1bc243 commit 29e991b

File tree

6 files changed

+139
-92
lines changed

6 files changed

+139
-92
lines changed

docs/book/src/topics/images/built-amis.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ New AMIs are built on a best effort basis when a new Kubernetes version is relea
99
- When there is a new k8s release series then any AMIs no longer covered by the previous point will be deleted. For example, when v1.31.0 is published then any AMIs for the v1.28 release series will be deleted.
1010
- Existing AMIs are not updated for security fixes and it is recommended to always use the latest patch version for the Kubernetes version you want to run.
1111

12-
> NOTE: As the old community images where located in an AWS account that the project no longer has access to and because those AMIs have been automatically deleted we have started publishing images again from v1.29.9
12+
> NOTE: As the old community images were located in an AWS account that the project no longer has access to and because those AMIs have been automatically deleted, we have started publishing images again starting from Kubernetes v1.29.9.
1313
1414
## Finding AMIs
1515

@@ -21,7 +21,7 @@ If you are using a version of clusterawsadm prior to v2.6.2 then you will need t
2121
- Ubuntu (ubuntu-22.04, ubuntu-24.04)
2222
- Flatcar (flatcar-stable)
2323

24-
> Note: Centos (centos-7) and Amazon Linux 2 (amazon-2) where supported but there are some issues with the AMI build that need fixing.
24+
> Note: Centos (centos-7) and Amazon Linux 2 (amazon-2) where supported but there are some issues with the AMI build that need fixing. See this [issue](https://github.com/kubernetes-sigs/cluster-api-provider-aws/issues/5142) for details.
2525
2626
## Supported AWS Regions
2727
- ap-northeast-1

test/e2e/data/e2e_conf.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -176,10 +176,10 @@ variables:
176176
# allowing the same e2e config file to be re-used in different Prow jobs e.g. each one with a K8s version permutation.
177177
# The following Kubernetes versions should be the latest versions with already published kindest/node images.
178178
# This avoids building node images in the default case which improves the test duration significantly.
179-
KUBERNETES_VERSION_MANAGEMENT: "v1.30.2"
180-
KUBERNETES_VERSION: "v1.26.6"
181-
KUBERNETES_VERSION_UPGRADE_TO: "v1.26.6"
182-
KUBERNETES_VERSION_UPGRADE_FROM: "v1.25.12"
179+
KUBERNETES_VERSION_MANAGEMENT: "v1.29.8"
180+
KUBERNETES_VERSION: "v1.29.9"
181+
KUBERNETES_VERSION_UPGRADE_TO: "v1.29.9"
182+
KUBERNETES_VERSION_UPGRADE_FROM: "v1.29.8"
183183
# Pre and post 1.23 Kubernetes versions are being used for CSI upgrade tests
184184
PRE_1_23_KUBERNETES_VERSION: "v1.22.17"
185185
POST_1_23_KUBERNETES_VERSION: "v1.23.15"
@@ -190,11 +190,11 @@ variables:
190190
AWS_NODE_MACHINE_TYPE: t3.large
191191
AWS_MACHINE_TYPE_VCPU_USAGE: 2
192192
AWS_SSH_KEY_NAME: "cluster-api-provider-aws-sigs-k8s-io"
193-
CONFORMANCE_CI_ARTIFACTS_KUBERNETES_VERSION: "v1.29.1"
193+
CONFORMANCE_CI_ARTIFACTS_KUBERNETES_VERSION: "v1.29.9"
194194
CONFORMANCE_WORKER_MACHINE_COUNT: "5"
195195
CONFORMANCE_CONTROL_PLANE_MACHINE_COUNT: "3"
196196
ETCD_VERSION_UPGRADE_TO: "3.5.11-0"
197-
COREDNS_VERSION_UPGRADE_TO: "v1.9.4"
197+
COREDNS_VERSION_UPGRADE_TO: "v1.11.1"
198198
MULTI_TENANCY_ROLE_NAME: "multi-tenancy-role"
199199
MULTI_TENANCY_NESTED_ROLE_NAME: "multi-tenancy-nested-role"
200200
IP_FAMILY: "IPv4"
@@ -206,7 +206,7 @@ variables:
206206
INIT_WITH_BINARY_V1BETA1: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.2.0/clusterctl-{OS}-{ARCH}"
207207
# INIT_WITH_KUBERNETES_VERSION are only used by the clusterctl upgrade test to initialize
208208
# the management cluster to be upgraded.
209-
INIT_WITH_KUBERNETES_VERSION: "v1.25.12"
209+
INIT_WITH_KUBERNETES_VERSION: "v1.29.8"
210210
EXP_BOOTSTRAP_FORMAT_IGNITION: "true"
211211
EXP_KUBEADM_BOOTSTRAP_FORMAT_IGNITION: "true"
212212
EXP_EXTERNAL_RESOURCE_GC: "true"

test/e2e/suites/unmanaged/helpers_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ func makeJoinBootstrapConfigTemplate(namespace, name string) *bootstrapv1.Kubead
529529
JoinConfiguration: &bootstrapv1.JoinConfiguration{
530530
NodeRegistration: bootstrapv1.NodeRegistrationOptions{
531531
Name: "{{ ds.meta_data.local_hostname }}",
532-
KubeletExtraArgs: map[string]string{"cloud-provider": "aws"},
532+
KubeletExtraArgs: map[string]string{"cloud-provider": "external"},
533533
},
534534
},
535535
},

test/e2e/suites/unmanaged/unmanaged_CAPI_clusterclass_test.go

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework] [ClusterClass]", fun
4141
Expect(e2eCtx.Environment.BootstrapClusterProxy).ToNot(BeNil(), "Invalid argument. BootstrapClusterProxy can't be nil")
4242
})
4343

44-
ginkgo.Describe("Self Hosted Spec [ClusterClass]", func() {
44+
ginkgo.PDescribe("Self Hosted Spec [ClusterClass]", func() {
4545
ginkgo.BeforeEach(func() {
4646
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
4747
requiredResources = &shared.TestResource{EC2Normal: 2 * e2eCtx.Settings.InstanceVCPU, IGW: 1, NGW: 1, VPC: 1, ClassicLB: 1, EIP: 1, EventBridgeRules: 50}
@@ -65,12 +65,14 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework] [ClusterClass]", fun
6565
})
6666
})
6767

68-
ginkgo.Describe("Cluster Upgrade Spec - HA control plane with workers [K8s-Upgrade] [ClusterClass]", func() {
68+
ginkgo.PDescribe("Cluster Upgrade Spec - HA control plane with workers [K8s-Upgrade] [ClusterClass]", func() {
6969
ginkgo.BeforeEach(func() {
70-
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
71-
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
72-
requiredResources.WriteRequestedResources(e2eCtx, "capi-cluster-upgrade-clusterclass-test")
73-
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
70+
if !e2eCtx.Settings.SkipQuotas {
71+
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
72+
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
73+
requiredResources.WriteRequestedResources(e2eCtx, "capi-cluster-upgrade-clusterclass-test")
74+
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
75+
}
7476
})
7577

7678
capi_e2e.ClusterUpgradeConformanceSpec(ctx, func() capi_e2e.ClusterUpgradeConformanceSpecInput {
@@ -87,16 +89,20 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework] [ClusterClass]", fun
8789
})
8890

8991
ginkgo.AfterEach(func() {
90-
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
92+
if !e2eCtx.Settings.SkipQuotas {
93+
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
94+
}
9195
})
9296
})
9397

9498
ginkgo.Describe("ClusterClass Changes Spec - SSA immutability checks [ClusterClass]", func() {
9599
ginkgo.BeforeEach(func() {
96-
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
97-
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
98-
requiredResources.WriteRequestedResources(e2eCtx, "capi-cluster-ssa-clusterclass-test")
99-
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
100+
if !e2eCtx.Settings.SkipQuotas {
101+
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
102+
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
103+
requiredResources.WriteRequestedResources(e2eCtx, "capi-cluster-ssa-clusterclass-test")
104+
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
105+
}
100106
})
101107

102108
capi_e2e.ClusterClassChangesSpec(ctx, func() capi_e2e.ClusterClassChangesSpecInput {
@@ -133,7 +139,9 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework] [ClusterClass]", fun
133139
})
134140

135141
ginkgo.AfterEach(func() {
136-
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
142+
if !e2eCtx.Settings.SkipQuotas {
143+
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
144+
}
137145
})
138146
})
139147
})

test/e2e/suites/unmanaged/unmanaged_CAPI_test.go

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,12 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework]", func() {
8888

8989
ginkgo.Describe("Self Hosted Spec", func() {
9090
ginkgo.BeforeEach(func() {
91-
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
92-
requiredResources = &shared.TestResource{EC2Normal: 2 * e2eCtx.Settings.InstanceVCPU, IGW: 1, NGW: 1, VPC: 1, ClassicLB: 1, EIP: 1, EventBridgeRules: 50}
93-
requiredResources.WriteRequestedResources(e2eCtx, "capi-clusterctl-self-hosted-test")
94-
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
91+
if !e2eCtx.Settings.SkipQuotas {
92+
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
93+
requiredResources = &shared.TestResource{EC2Normal: 2 * e2eCtx.Settings.InstanceVCPU, IGW: 1, NGW: 1, VPC: 1, ClassicLB: 1, EIP: 1, EventBridgeRules: 50}
94+
requiredResources.WriteRequestedResources(e2eCtx, "capi-clusterctl-self-hosted-test")
95+
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
96+
}
9597
})
9698

9799
capi_e2e.SelfHostedSpec(ctx, func() capi_e2e.SelfHostedSpecInput {
@@ -105,16 +107,20 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework]", func() {
105107
}
106108
})
107109
ginkgo.AfterEach(func() {
108-
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
110+
if !e2eCtx.Settings.SkipQuotas {
111+
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
112+
}
109113
})
110114
})
111115

112-
ginkgo.Describe("Clusterctl Upgrade Spec [from latest v1beta1 release to v1beta2]", func() {
116+
ginkgo.PDescribe("Clusterctl Upgrade Spec [from latest v1beta1 release to v1beta2]", func() {
113117
ginkgo.BeforeEach(func() {
114-
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
115-
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
116-
requiredResources.WriteRequestedResources(e2eCtx, "capi-clusterctl-upgrade-test-v1beta1-to-v1beta2")
117-
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
118+
if !e2eCtx.Settings.SkipQuotas {
119+
// As the resources cannot be defined by the It() clause in CAPI tests, using the largest values required for all It() tests in this CAPI test.
120+
requiredResources = &shared.TestResource{EC2Normal: 5 * e2eCtx.Settings.InstanceVCPU, IGW: 2, NGW: 2, VPC: 2, ClassicLB: 2, EIP: 2, EventBridgeRules: 50}
121+
requiredResources.WriteRequestedResources(e2eCtx, "capi-clusterctl-upgrade-test-v1beta1-to-v1beta2")
122+
Expect(shared.AcquireResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))).To(Succeed())
123+
}
118124
})
119125

120126
capi_e2e.ClusterctlUpgradeSpec(ctx, func() capi_e2e.ClusterctlUpgradeSpecInput {
@@ -135,7 +141,9 @@ var _ = ginkgo.Context("[unmanaged] [Cluster API Framework]", func() {
135141
}
136142
})
137143
ginkgo.AfterEach(func() {
138-
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
144+
if !e2eCtx.Settings.SkipQuotas {
145+
shared.ReleaseResources(requiredResources, ginkgo.GinkgoParallelProcess(), flock.New(shared.ResourceQuotaFilePath))
146+
}
139147
})
140148
})
141149

0 commit comments

Comments
 (0)