gordonwatts / atlas-containers

2 stars 1 forks source link

do `yum clean` in a better way #2

Closed gordonwatts closed 11 months ago

gordonwatts commented 11 months ago
Aside: If you want to take advantage of yum clean cleaning up and removing packages in a container then you need to run it in the same RUN command as the installation step. Each RUN command generates a new zipfile layer to the container image so if you clean after the RUN command that installed things you only cleaned the layer above, and things are still in the final image just sitting around as extra storage bloat.

From Matthew F!!

gordonwatts commented 11 months ago

On AL9 this made no difference in size that was detectable!

gordonwatts commented 11 months ago

Same with CENTOS7 - no change