Skip to content

Commit 0b0695b

Browse files
drop cgroup-driver patch
1 parent 9a6b99b commit 0b0695b

File tree

16 files changed

+161
-213
lines changed

16 files changed

+161
-213
lines changed

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,6 @@ generate-e2e-templates-main: $(KUSTOMIZE)
536536
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-machine-pool --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-machine-pool.yaml
537537
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-node-drain --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-node-drain.yaml
538538
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-upgrades --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-upgrades.yaml
539-
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-upgrades-cgroupfs --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-upgrades-cgroupfs.yaml
540539
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-upgrades-runtimesdk --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-upgrades-runtimesdk.yaml
541540
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-kcp-scale-in --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-kcp-scale-in.yaml
542541
$(KUSTOMIZE) build $(DOCKER_TEMPLATES)/main/cluster-template-ipv6 --load-restrictor LoadRestrictionsNone > $(DOCKER_TEMPLATES)/main/cluster-template-ipv6.yaml

cmd/clusterctl/client/cluster/assets/topology-test/existing-my-cluster.yaml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,18 +87,10 @@ spec:
8787
scheduler: {}
8888
initConfiguration:
8989
localAPIEndpoint: {}
90-
nodeRegistration:
91-
criSocket: unix:///var/run/containerd/containerd.sock
92-
kubeletExtraArgs:
93-
cgroup-driver: cgroupfs
94-
eviction-hard: nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%
90+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
9591
joinConfiguration:
9692
discovery: {}
97-
nodeRegistration:
98-
criSocket: unix:///var/run/containerd/containerd.sock
99-
kubeletExtraArgs:
100-
cgroup-driver: cgroupfs
101-
eviction-hard: nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%
93+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
10294
machineTemplate:
10395
infrastructureRef:
10496
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1

cmd/clusterctl/client/cluster/assets/topology-test/existing-my-second-cluster.yaml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -88,18 +88,10 @@ spec:
8888
scheduler: {}
8989
initConfiguration:
9090
localAPIEndpoint: {}
91-
nodeRegistration:
92-
criSocket: unix:///var/run/containerd/containerd.sock
93-
kubeletExtraArgs:
94-
cgroup-driver: cgroupfs
95-
eviction-hard: nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%
91+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
9692
joinConfiguration:
9793
discovery: {}
98-
nodeRegistration:
99-
criSocket: unix:///var/run/containerd/containerd.sock
100-
kubeletExtraArgs:
101-
cgroup-driver: cgroupfs
102-
eviction-hard: nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%
94+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
10395
machineTemplate:
10496
infrastructureRef:
10597
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1

cmd/clusterctl/client/cluster/assets/topology-test/my-cluster-class.yaml

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -55,21 +55,9 @@ spec:
5555
apiServer:
5656
certSANs: [ localhost, 127.0.0.1 ]
5757
initConfiguration:
58-
nodeRegistration:
59-
criSocket: unix:///var/run/containerd/containerd.sock
60-
kubeletExtraArgs:
61-
# We have to pin the cgroupDriver to cgroupfs as kubeadm >=1.21 defaults to systemd
62-
# kind will implement systemd support in: https://github.com/kubernetes-sigs/kind/issues/1726
63-
cgroup-driver: cgroupfs
64-
eviction-hard: 'nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%'
58+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
6559
joinConfiguration:
66-
nodeRegistration:
67-
criSocket: unix:///var/run/containerd/containerd.sock
68-
kubeletExtraArgs:
69-
# We have to pin the cgroupDriver to cgroupfs as kubeadm >=1.21 defaults to systemd
70-
# kind will implement systemd support in: https://github.com/kubernetes-sigs/kind/issues/1726
71-
cgroup-driver: cgroupfs
72-
eviction-hard: 'nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%'
60+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
7361
version: v1.21.2
7462
---
7563
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1

cmd/clusterctl/client/cluster/assets/topology-test/new-clusterclass-and-cluster.yaml

Lines changed: 3 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -95,21 +95,9 @@ spec:
9595
apiServer:
9696
certSANs: [ localhost, 127.0.0.1 ]
9797
initConfiguration:
98-
nodeRegistration:
99-
criSocket: unix:///var/run/containerd/containerd.sock
100-
kubeletExtraArgs:
101-
# We have to pin the cgroupDriver to cgroupfs as kubeadm >=1.21 defaults to systemd
102-
# kind will implement systemd support in: https://github.com/kubernetes-sigs/kind/issues/1726
103-
cgroup-driver: cgroupfs
104-
eviction-hard: 'nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%'
98+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
10599
joinConfiguration:
106-
nodeRegistration:
107-
criSocket: unix:///var/run/containerd/containerd.sock
108-
kubeletExtraArgs:
109-
# We have to pin the cgroupDriver to cgroupfs as kubeadm >=1.21 defaults to systemd
110-
# kind will implement systemd support in: https://github.com/kubernetes-sigs/kind/issues/1726
111-
cgroup-driver: cgroupfs
112-
eviction-hard: 'nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%'
100+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
113101
version: v1.21.2
114102
---
115103
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
@@ -146,12 +134,7 @@ spec:
146134
template:
147135
spec:
148136
joinConfiguration:
149-
nodeRegistration:
150-
kubeletExtraArgs:
151-
# We have to pin the cgroupDriver to cgroupfs as kubeadm >=1.21 defaults to systemd
152-
# kind will implement systemd support in: https://github.com/kubernetes-sigs/kind/issues/1726
153-
cgroup-driver: cgroupfs
154-
eviction-hard: 'nodefs.available<0%,nodefs.inodesFree<0%,imagefs.available<0%'
137+
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use.
155138

156139
---
157140
apiVersion: cluster.x-k8s.io/v1beta1

test/e2e/cluster_upgrade_test.go

Lines changed: 1 addition & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -20,45 +20,20 @@ limitations under the License.
2020
package e2e
2121

2222
import (
23-
"github.com/blang/semver"
2423
. "github.com/onsi/ginkgo/v2"
25-
. "github.com/onsi/gomega"
2624
"k8s.io/utils/pointer"
2725
)
2826

2927
var _ = Describe("When upgrading a workload cluster using ClusterClass and testing K8S conformance [Conformance] [K8s-Upgrade] [ClusterClass]", func() {
3028
ClusterUpgradeConformanceSpec(ctx, func() ClusterUpgradeConformanceSpecInput {
31-
// "upgrades" is the same as the "topology" flavor but with an additional MachinePool.
32-
flavor := pointer.String("upgrades")
33-
// For KubernetesVersionUpgradeFrom < v1.24 we have to use upgrades-cgroupfs flavor.
34-
// This is because kind and CAPD only support:
35-
// * cgroupDriver cgroupfs for Kubernetes < v1.24
36-
// * cgroupDriver systemd for Kubernetes >= v1.24.
37-
// Notes:
38-
// * We always use a ClusterClass-based cluster-template for the upgrade test
39-
// * The ClusterClass will automatically adjust the cgroupDriver for KCP and MDs.
40-
// * We have to handle the MachinePool ourselves
41-
// * The upgrades-cgroupfs flavor uses an MP which is pinned to cgroupfs
42-
// * During the upgrade UpgradeMachinePoolAndWait automatically drops the cgroupfs pinning
43-
// when the target version is >= v1.24.
44-
// We can remove this as soon as we don't test upgrades from Kubernetes < v1.24 anymore with CAPD
45-
// or MachinePools are supported in ClusterClass.
46-
version, err := semver.ParseTolerant(e2eConfig.GetVariable(KubernetesVersionUpgradeFrom))
47-
Expect(err).ToNot(HaveOccurred(), "Invalid argument, KUBERNETES_VERSION_UPGRADE_FROM is not a valid version")
48-
if version.LT(semver.MustParse("1.24.0")) {
49-
// "upgrades-cgroupfs" is the same as the "topology" flavor but with an additional MachinePool
50-
// with pinned cgroupDriver to cgroupfs.
51-
flavor = pointer.String("upgrades-cgroupfs")
52-
}
53-
5429
return ClusterUpgradeConformanceSpecInput{
5530
E2EConfig: e2eConfig,
5631
ClusterctlConfigPath: clusterctlConfigPath,
5732
BootstrapClusterProxy: bootstrapClusterProxy,
5833
ArtifactFolder: artifactFolder,
5934
SkipCleanup: skipCleanup,
60-
Flavor: flavor,
6135
InfrastructureProvider: pointer.String("docker"),
36+
Flavor: pointer.String("upgrades"),
6237
}
6338
})
6439
})

test/e2e/config/docker.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,6 @@ providers:
234234
- sourcePath: "../data/infrastructure-docker/main/cluster-template-machine-pool.yaml"
235235
- sourcePath: "../data/infrastructure-docker/main/cluster-template-node-drain.yaml"
236236
- sourcePath: "../data/infrastructure-docker/main/cluster-template-upgrades.yaml"
237-
- sourcePath: "../data/infrastructure-docker/main/cluster-template-upgrades-cgroupfs.yaml"
238237
- sourcePath: "../data/infrastructure-docker/main/cluster-template-upgrades-runtimesdk.yaml"
239238
- sourcePath: "../data/infrastructure-docker/main/cluster-template-kcp-scale-in.yaml"
240239
- sourcePath: "../data/infrastructure-docker/main/cluster-template-ipv6.yaml"

test/e2e/data/infrastructure-docker/main/cluster-template-upgrades-cgroupfs/kustomization.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

test/e2e/data/infrastructure-docker/main/cluster-template-upgrades-cgroupfs/mp-cgroupfs.yaml

Lines changed: 0 additions & 13 deletions
This file was deleted.

test/e2e/data/infrastructure-docker/main/cluster-template-upgrades-cgroupfs/mp-default-cgroupfs.yaml

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)