Kill a Running Docker Container

When running Docker workloads on localhost, cluster or remote host, there are cases when a container will not stop gracefully, and a more direct approach is needed to stop the container.

Docker Kill

For the above reason, the Docker CLI has the docker kill command, which gives up the option to kill a running container without waiting for it to stop gracefully.

To kill a running container, use the following command

docker kill deploy01

In the above case, deploy01 is the container name.

Published
Categorized as Docker

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.