This is a quick post about Docker. It uses a lot of space for volumes, images, containers, etc…

Most of the times, at least for the applications I use Docker, it uses too much space for volumes.

In order to free space used by Docker:

  • start the containers you want to keep
    • by doing this, the elements related to these containers will not be removed
  • run docker system prune –volumes
    • this will free up a lot of space.

See that even if you run docker system prune –all, the volumes will NOT be removed. That is why you must specify the --volumes parameter in the command. I was expecting that the --all included the volumes as well but this is not the case with Docker 20.10.