Created
March 19, 2019 16:00
-
-
Save hsaputra/6c5641aca130d3bf4d73e3e63197c9b5 to your computer and use it in GitHub Desktop.
Docker - remove all containers based on container id
This file contains 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
# for each container ID use the docker "rm" command to remove/delete the container | |
!for cid in $(docker ps -a | awk '{print $1}' | tail -n +2);do docker rm $cid; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment