Card 07/ 07
All 7 cards
RecapDifficulty: Advanced1 min
What You Learned
- Each instruction leaves a layer, and a layer is the unit of both caching and disk.
- The cache is a chain: once a layer changes, everything below it runs again.
- Copy the manifest, install, then copy the source, so an edit cannot invalidate the install.
docker system dfsays what is reclaimable, and the build cache is usually most of it.prune --volumesis the dangerous one, because a stopped database's data looks unused.