crun
crun copied to clipboard
cgroup: do not create a sub-cgroup by default
trafficstars
The run.oci.systemd.subgroup annotation previously defaulted to creating a "container" sub-cgroup on cgroup v2 systems if the annotation was not specified. This change alters the behavior so that no sub-cgroup is created by default.
A sub-cgroup will only be created if the
run.oci.systemd.subgroup annotation is explicitly provided with a non-empty value.
Closes: https://github.com/containers/crun/issues/1766
Summary by Sourcery
Change default systemd sub-cgroup behavior to only create a sub-cgroup when the run.oci.systemd.subgroup annotation is explicitly set with a non-empty value.
Enhancements:
- Make
run.oci.systemd.subgroupdefault to no sub-cgroup instead of "container" and returnNULLin code when unset.
Documentation:
- Update man pages and Markdown docs to reflect that no sub-cgroup is created by default unless explicitly configured.