Created
March 8, 2018 20:09
-
-
Save lhriley/4f890b3fcabfd3759cd7e3c540abc5f3 to your computer and use it in GitHub Desktop.
Quickly kill a named docker container without knowing all of the details of it
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| service="DOCKER_CONTAINER"; docker kill $(docker ps | grep "${service}" | awk '{print $1}') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment