March 2017
Beginner to intermediate
925 pages
18h 11m
English
Dockerfiles help us in automating image creation and getting precisely the same image every time we want it. The Docker builder reads instructions from a text file (a Dockerfile) and executes them one after the other in order. It can be compared as Vagrant files, which allows you to configure VMs in a predictable manner.
A Dockerfile with build instructions.
$ mkdir sample_image $ cd sample_image
Dockerfile with the following content:$ cat Dockerfile # Pick up the base image FROM fedora # Add author name MAINTAINER Neependra Khare # Add the command to run at the start of container CMD date
Read now
Unlock full access