3 ms·
I'm confused by this. You obviously have a process to build new images... why doesn't the same process prune old ones ?
by mobiuscog 10y ago
I'm confused by this.
You obviously have a process to build new images... why doesn't the same process prune old ones ?
- n0us 10y agoNo, there is no simple command to remove old images because the creators of docker want you to compose other existing commands to delete them and it would be unnecessary to add a command. IMO this is a terrible decision but that was apparently the rationalization.
- thaJeztah 10y agoA new "docker prune" command is added to docker 1.13 to address this, see https://github.com/docker/docker/pull/26108 https://github.com/docker/docker/pull/26108
- FuNe 10y agoThat's what I do but given that the process is run in parallel being part of a complex CI system I needed to write quite a bit of logic to do the pruning safely myself. Main problem being that I couldn't rely on docker daemon not deleting images that might actually be still needed by other processes building in parallel.