-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
CGroup device configuration in prestart hook #1044
Comments
This is intended behaviour. The reason for this change is because of the fact that the Go runtime loves to consume resources (especially PIDs), and setting the limits earlier would result in the author of a It should be noted that if you use the |
I see it makes sense. Yes, I'm aware of the Can't we just move the cgroup assignment only for the device subsystem? This shouldn't impact runc apart from the /dev/null reopen. I'm not sure about the other subsystems but the device wildcard override looks like an edge case that could be handled this way. |
Any insights on this? This is the only thing stopping us from adding GPU support for runc/Docker. |
Fixed by #1239 |
Currently the container process joins its cgroup before the hooks are triggered (source) but the configuration is actually applied later when the
procReady
signal is received (source).Is that the intended behavior? I'm asking because it makes it impossible to configure the device cgroup from within a prestart hook if the author of the hook doesn't control the runc config. The first device rule will most likely be
{Major: Wildcard, Minor: Wildcard, Allow: false}
or setAllowAllDevices: false
thus overriding any cgroup configuration made by the hook itself.The text was updated successfully, but these errors were encountered: