You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: runtime.md
+7-6
Original file line number
Diff line number
Diff line change
@@ -129,18 +129,19 @@ This operation MUST run the user-specified program as specified by [`process`](c
129
129
This operation MUST generate an error if `process` was not set.
130
130
131
131
### <aname="runtimeKill" />Kill
132
-
`kill <container-id> <signal>`
132
+
`kill <container-id> [-a,--all] <signal>`
133
133
134
134
This operation MUST [generate an error](#errors) if it is not provided the container ID.
135
-
Attempting to send a signal to a container that is neither [`created` nor `running`](#state) MUST have no effect on the container and MUST [generate an error](#errors).
136
-
This operation MUST send the specified signal to the container process.
135
+
This operation MUST send the specified signal to the container process(without `-a`) or to all processes in the container(with `-a`).
136
+
Without `-a`, attempting to send a signal to a container that is neither [`created` nor `running`](#state) MUST have no effect on the container and MUST [generate an error](#errors).
137
137
138
138
### <aname="runtimeDelete" />Delete
139
-
`delete <container-id>`
139
+
`delete [-f,--force] <container-id>`
140
140
141
141
This operation MUST [generate an error](#errors) if it is not provided the container ID.
142
-
Attempting to `delete` a container that is not [`stopped`](#state) MUST have no effect on the container and MUST [generate an error](#errors).
143
-
Deleting a container MUST delete the resources that were created during the `create` step.
142
+
Without `-f`, attempting to `delete` a container that is not [`stopped`](#state) MUST have no effect on the container and MUST [generate an error](#errors).
143
+
With `-f`, runtime should try its best to delete the container no matter what the state is.
144
+
Deleting a container MUST delete the resources that were created during the `create` step, specially, if the container uses `shared pid namespace`, all processes inside the container's cgroup should also be killed first.
144
145
Note that resources associated with the container, but not created by this container, MUST NOT be deleted.
145
146
Once a container is deleted its ID MAY be used by a subsequent container.
0 commit comments