Empirical Study of the Docker Smells Impact on the Image Size
Thomas Durieux
Abstract
Docker, a widely adopted tool for packaging and deploying applications leverages Dockerfiles to build images. However, creating an optimal Dockerfile can be challenging, often leading to "Docker smells" or deviations from best practices. This paper presents a study of the impact of 14 Docker smells on the size of Docker images. To assess the size impact of Docker smells, we identified and repaired 16 145 Docker smells from 11 313 open-source Dockerfiles. We observe that the smells result in an average increase of 48.06 MB (4.6 %) per smelly image. Depending on the smell type, the size increase can be up to 10 %, and for some specific cases, the smells can represent 89 % of the image size. Interestingly, the most impactful smells are related to package managers which are commonly encountered and are relatively easy to fix. To collect the perspective of the developers regarding the size impact of the Docker smells, we submitted 34 pull requests that repair the smells and we reported their impact on the Docker image to the developers. 26/34 (76.5 %) of the pull requests have been merged and they contribute to a saving of 3.46 GB (16.4 %). The developer's comments demonstrate a positive interest in addressing those Docker smells even when the pull requests have been rejected.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 83b1a5e8-6861-4e8a-853e-55f0a6e4083cCited by top-tier papers3
- Dockerfile Flakiness: Characterization and RepairTaha Shabani, Noor Nashid, Parsa Alian, Ali MesbahICSE 2025 · 2 citations
- Unveiling the Energy Vampires: A Methodology for Debugging Software Energy ConsumptionEnrique Barba Roque, Luis Cruz, Thomas DurieuxICSE 2025 · 2 citations
- Doctor: Optimizing Container Rebuild Efficiency by Instruction Re-orchestrationZhiling Zhu, Tieming Chen, Chengwei Liu, Han Liu et al.ISSTA 2025
Builds on4
- DupHunter: Flexible High-Performance Deduplication for Docker RegistriesNannan Zhao, Hadeel Albahar, Subil Abraham, Keren Chen et al.USENIX ATC 2020 · 54 citations
- Learning from, understanding, and supporting DevOps artifacts for dockerJordan Henkel, Christian Bird, Shuvendu K. Lahiri, Thomas W. RepsICSE 2020 · 50 citations
- Shipwright: A Human-in-the-Loop System for Dockerfile RepairJordan Henkel, Denini Silva, Leopoldo Teixeira, Marcelo d'Amorim et al.ICSE 2021 · 31 citations
- Refactorings and Technical Debt in Docker Projects: An Empirical StudyEmna Ksontini, Marouane Kessentini, Thiago do Nascimento Ferreira, Foyzul HassanASE 2021 · 17 citations
Related papers
- Configuration smells in continuous delivery pipelines: a linter and a six-month study on GitLabCarmine Vassallo, Sebastian Proksch, Anna Jancso, Harald C. Gall et al.FSE 2020 · 43 citations
- BuildSonic: Detecting and Repairing Performance-Related Configuration Smells for Continuous Integration BuildsChen Zhang, Bihuan Chen, Junhao Hu, Xin Peng et al.ASE 2022 · 11 citations
- Your Build Scripts Stink: The State of Code Smells in Build ScriptsMahzabin Tamanna, Yash Chandrani, Matthew Burrows, Brandon Wroblewski et al.ASE 2025 · 1 citation
- Understanding and Predicting Docker Build Duration: An Empirical Study of Containerized Workflow of OSS ProjectsYiwen Wu, Yang Zhang, Kele Xu, Tao Wang et al.ASE 2022 · 13 citations
- Towards Understanding Docker Build Faults in Practice: Symptoms, Root Causes, and Fix PatternsYiwen Wu, Yang Zhang, Tao Wang, Bo Ding et al.FSE 2025 · 4 citations
