-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
add default sysctls to allow privileged ports with no capabilities #18421
Conversation
Seems like this is something that should at least be documented upstream, for changing the runtime settings... https://kubernetes.io/docs/setup/production-environment/container-runtimes/ |
Releated issue, about adding non-default config to kind: |
there's a notion to go even further - by k8s requiring this from cri: kubernetes/kubernetes#102612 (comment) also, containerd plans to have it enabled by default in v2.0: containerd/containerd#6924 |
I don't think that is a big issue, just wondering if minikube should follow rather than lead? |
/ok-to-test |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
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.
Just two super small things in the comments
Co-authored-by: Steven Powell <44844360+spowelljr@users.noreply.github.com>
Co-authored-by: Steven Powell <44844360+spowelljr@users.noreply.github.com>
eagle eye 🙂 |
kvm2 driver with docker runtime
Times for minikube start: 50.4s 52.2s 53.1s 56.0s 53.0s Times for minikube ingress: 25.7s 26.1s 25.6s 25.7s 27.6s docker driver with docker runtime
Times for minikube ingress: 20.3s 20.3s 20.3s 20.3s 20.3s Times for minikube start: 22.5s 22.6s 25.6s 25.1s 22.1s docker driver with containerd runtime
Times for minikube start: 21.9s 21.1s 20.4s 20.8s 23.6s Times for minikube ingress: 30.8s 31.3s 31.3s 29.8s 45.8s |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: prezha, spowelljr 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 |
These are the flake rates of all failed tests.
Too many tests failed - See test logs for more details. To see the flake rates of all tests by environment, click here. |
this pr adds
net.ipv4.ip_unprivileged_port_start
sysctls as default tocontainerd
andcri-o
container runtimes to allow privileged ports to be used by containers run by a non-root user forkubernetes v1.22+
background
during testing the bump of kubernetes default version to v1.29.2, we discovered that
coredns
would not come up if containerd or cri-o container runtimes are used with the docker driver (example: conainerd and cri-o)the coredns errored with:
Listen: listen tcp :53: bind: permission denied
kubernetes v1.29.0+ uses coredns v1.11.1 and from v1.11.0, coredns runs as non-root user
some additional details about the issue also observed elsewhere can be found eg, here and here
since starting from kubernetes v1.22, the required net.ipv4.ip_unprivileged_port_start sysctl was marked as safe, but it's up to the container runtime to implement it - docker already has it enabled by default, whereas other CRIs have that as option but it's not enabled by default (containerd and cri-o) and this pr tries to address those two and enable corresponding options