Skip to content

Commit 7001e02

Browse files
committed
disable hard eviction by default
1 parent 17c3fc4 commit 7001e02

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

pkg/cluster/internal/kubeadm/config.go

+17
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,13 @@ apiServerExtraVolumes:
9090
# so we need to ensure the cert is valid for localhost so we can talk
9191
# to the cluster after rewriting the kubeconfig to point to localhost
9292
apiServerCertSANs: [localhost]
93+
kubeletConfiguration:
94+
baseConfig:
95+
evictionHard:
96+
memory.available: "1"
97+
nodefs.available: "0%"
98+
nodefs.inodesFree: "0%"
99+
imagefs.available: "0%"
93100
`
94101

95102
// ConfigTemplateAlphaV3 is the kubadm config template for API version v1alpha3
@@ -131,6 +138,11 @@ kind: JoinConfiguration
131138
# no-op entry that exists soley so it can be patched
132139
apiVersion: kubelet.config.k8s.io/v1beta1
133140
kind: KubeletConfiguration
141+
evictionHard:
142+
memory.available: "1"
143+
nodefs.available: "0%"
144+
nodefs.inodesFree: "0%"
145+
imagefs.available: "0%"
134146
---
135147
# no-op entry that exists soley so it can be patched
136148
apiVersion: kubeproxy.config.k8s.io/v1alpha1
@@ -169,6 +181,11 @@ kind: JoinConfiguration
169181
# no-op entry that exists soley so it can be patched
170182
apiVersion: kubelet.config.k8s.io/v1beta1
171183
kind: KubeletConfiguration
184+
evictionHard:
185+
memory.available: "1"
186+
nodefs.available: "0%"
187+
nodefs.inodesFree: "0%"
188+
imagefs.available: "0%"
172189
---
173190
# no-op entry that exists soley so it can be patched
174191
apiVersion: kubeproxy.config.k8s.io/v1alpha1

0 commit comments

Comments
 (0)