November 2018
Beginner
230 pages
6h 4m
English
As you may guess, the ENV instruction is used to define environment variables that will be set in the running containers created from the image being built. The variables are defined using typical key-value pairs. A Dockerfile can have one or more ENV instructions. Here is the ENV instruction syntax:
# ENV instruction syntax# This is the form to create a single environment variable per instruction# Everything after the space following the <key> becomes the valueENV <key> <value># This is the form to use when you want to create more than one variable per instructionENV <key>=<value> ...
Each ENV instruction will create one or more environment variables (unless the key name is repeated). Let's take a look at some ENV instructions ...
Read now
Unlock full access