Docker released the multi-stage builds feature in the version 17.05. This allowed developers to build smaller Docker images by using a final stage containing the minimum required for the application to work. Even though this is being used more and more over time, there are still multi-stage patterns that are not that widely used.
In this post I’ll show you how to use multi-stage builds to:
- avoid having different Dockerfiles for every environment
- copy files from remote images
- use parameters in the