Removal
Docker action always involving a large amount of cache, e.g. layers, docker image…etc
But in our development environment, it could accumulate easily after a few projects, which results in the out of storage or not enough memory for docker execution.
In this page, there are various docker technique for cleaning useless storage.
All-in-One
clean up any resources — images, containers, volumes, and networks
# — that are *dangling* (not tagged or associated with a container):
docker system prune
# Or — all stopped containers and all unused images
docker system prune -a
Images
Single image
All dangling images
ALL images
Containers
Single container
Remove all exited