Intro Guide to Dockerfile Best Practices
especially whilst I've been automating the build of Docker images via Jenkins pipelines.
Definitely a few tips to try, such as: -
Tip #4: Remove unnecessary dependencies
Remove unnecessary dependencies and do not install debugging tools. If needed debugging tools can always be installed later. Certain package managers such as apt, automatically install packages that are recommended by the user-specified package, unnecessarily increasing the footprint. Apt has the –no-install-recommends flag which ensures that dependencies that were not actually needed are not installed. If they are needed, add them explicitly.
Go read !
No comments:
Post a Comment