What is Build cache in Docker?

When we build an Image, Docker will process each line in the Docker file. It will execute the commands on each line in the order that is mentioned in the file. But at each line, before running any command, Docker will check if the reis already an existing image in its cache that can be reused rather than creating a new image. This method of using cacheinDocker iscalled Build cacheinDocker. We can also specify the option –no-cache=trueto to let Docker know that we do not want to use cache for Images. With this option, Docker will create all new images.