MCPcopy
hub / github.com/docker/docker-py / kill

Method kill

docker/models/containers.py:279–291  ·  view source on GitHub ↗

Kill or send a signal to the container. Args: signal (str or int): The signal to send. Defaults to ``SIGKILL`` Raises: :py:class:`docker.errors.APIError` If the server returns an error.

(self, signal=None)

Source from the content-addressed store, hash-verified

277 chunk_size, encode_stream)
278
279 def kill(self, signal=None):
280 """
281 Kill or send a signal to the container.
282
283 Args:
284 signal (str or int): The signal to send. Defaults to ``SIGKILL``
285
286 Raises:
287 :py:class:`docker.errors.APIError`
288 If the server returns an error.
289 """
290
291 return self.client.api.kill(self.id, signal=signal)
292
293 def logs(self, **kwargs):
294 """

Callers 15

test_listMethod · 0.45
test_list_sparseMethod · 0.45
test_killMethod · 0.45
test_reloadMethod · 0.45
test_killMethod · 0.45
test_kill_with_signalMethod · 0.45
test_portMethod · 0.45
test_topMethod · 0.45

Calls

no outgoing calls

Tested by 15

test_listMethod · 0.36
test_list_sparseMethod · 0.36
test_killMethod · 0.36
test_reloadMethod · 0.36
test_killMethod · 0.36
test_kill_with_signalMethod · 0.36
test_portMethod · 0.36
test_topMethod · 0.36