All languages

Docker

You're viewing a free preview. Sign in free to read every script.

Why this exists Every docker build leaves layers in the build cache. Every rebuild of a tag leaves the previous image behind, untagged. Every stopped container stays until removed, together with its writable layer. On a…

Docker Cleanup: Images, Containers & Build Cache

A cleanup script that shows a plan first and changes nothing until you say --apply, protects running containers and volumes by default, removes volumes only with two explicit flags, and works on a label-scoped set, with the real reasons docker prune has no dry-run and why "volume prune" may not remove the volume you expect.

Sign in free to read this script, along with the rest of the library.

Sign in free