Skip to content

Commit 81c9f31

Browse files
committed
Clarify cgroups path handling behavior
Signed-off-by: Mrunal Patel <[email protected]>
1 parent 3036273 commit 81c9f31

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

config-linux.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -183,13 +183,16 @@ If a `cgroupsPath` value is specified, the runtime MUST consistently attach to t
183183
Implementations of the Spec can choose to name cgroups in any manner.
184184
The Spec does not include naming schema for cgroups.
185185
The Spec does not support per-controller paths for the reasons discussed in the [cgroupv2 documentation][cgroup-v2].
186-
The cgroups will be created if they don't exist.
187186

188-
You can configure a container's cgroups via the `resources` field of the Linux configuration.
189-
Do not specify `resources` unless limits have to be updated.
187+
The runtime MUST create the cgroups specified by the `cgroupsPath` if they don't exist.
188+
If `cgroupsPath` is empty, then the behavior is runtime implementation specific.
189+
190+
The runtime MUST ensure that the container process is attached to the cgroups specified by `cgroupsPath`.
191+
If any property is set under `resources` then the runtime MUST set it for the container.
192+
Check individual properties for any specific handling.
193+
190194
For example, to run a new process in an existing container without updating limits, `resources` need not be specified.
191195

192-
Runtimes MAY attach the container process to additional cgroup controllers beyond those necessary to fulfill the `resources` settings.
193196

194197
### Example
195198

0 commit comments

Comments
 (0)