What is ONBUILD command in Docker?

We use ONBUILD command in Docker to run the instructions that have to execute after the completion of current Dockerfile build.
It is used to build a hierarchy of images that have to be build after the parent image is built.
A Docker build will execute first ONBUILD command and then it will execute any other command in Child Dockerfile.

Read the full book at www.amazon.com
Posted in Docker, Docker Interview Questions

Leave a Reply

Your email address will not be published. Required fields are marked *