To show all docker containers that are running you can use the following command:

docker ps -a 

show all docker containers

To show all docker images available use the following command

docker images -a

docker images

First we need to stop all running containers:

docker stop $(docker ps -a -q)

Next we remove all containers:

docker rm $(docker ps -a -q)

Then we can delete all used images:

docker rmi $(docker images -a -q)

No comments

Leave your comment

In reply to Some User