docker how to remove all stopped containers code example Example: docker remove all containers docker rm $(docker ps -a -q)