Remove Unused Containers, Networks, Images and Volumes
8 months ago
It's safe to run the following command while containers are running, because it removes only unused resources (not used by at least one container):
docker system prune --all --volumes
More information: How to remove old and unused Docker images