-
Notifications
You must be signed in to change notification settings - Fork 715
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
change config.yaml instead of args for fail-swap-on #2421
Conversation
kinder/pkg/build/bits/initBits.go
Outdated
@@ -280,7 +280,7 @@ func configureKubelet(c *BuildContext) error { | |||
|
|||
// ensure we don't fail if swap is enabled on the host | |||
if err := c.RunInContainer("/bin/sh", "-c", | |||
`echo "KUBELET_EXTRA_ARGS=--fail-swap-on=false" >> /etc/default/kubelet`, | |||
`echo "FailSwapOn: false" >> /var/lib/kubelet/config.yaml`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
kubeadm init and join regenerate this file and it will be overwritten.
the /etc/default/kubelet override does works but it's for flags only.
i think the option should be added here instead:
kubeadm/kinder/pkg/kubeadm/config.go
Lines 200 to 216 in 05f9b96
apiVersion: kubelet.config.k8s.io/v1beta1 | |
kind: KubeletConfiguration | |
metadata: | |
name: config | |
# configure ipv6 addresses in IPv6 mode | |
{{ if .IPv6 -}} | |
address: "::" | |
healthzBindAddress: "::" | |
{{- end }} | |
# disable disk resource management by default | |
# kubelet will see the host disk that the inner container runtime | |
# is ultimately backed by and attempt to recover disk space. we don't want that. | |
imageGCHighThresholdPercent: 100 | |
evictionHard: | |
nodefs.available: "0%" | |
nodefs.inodesFree: "0%" | |
imagefs.available: "0%" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
if the CI test here passes then the kubelet is receiving the failSwapOn: false
properly.
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: neolit123, pacoxu The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
https://storage.googleapis.com/kubernetes-jenkins/pr-logs/pull/100573/pull-kubernetes-e2e-kind-ipv6/1375269122421559296/artifacts/logs/kind-control-plane/kubelet.log
Fix warning logs in e2e testing envs.