July 2018
Intermediate to advanced
504 pages
11h 34m
English
Some Dockerfile instructions are shown in the table:
|
Instruction |
Description and examples |
|
FROM image[:tag] |
It sets the base image used in the build process. Examples: FROM httpd FROM httpd:2.2 |
|
RUN <command> <parameters> |
The RUN instruction executes any commands in a new layer on top of the current image and commits the results. Examples: RUN yum install -y httpd &&\ echo "custom answer" >/var/www/html/index.html |
|
RUN ["command", "param1", "param2"] |
This is the same as the last one but in Docker format. |
|
COPY <src> <dst> |
The COPY instruction copies new files from <src> and adds them to the filesystem of the container at the path <dest>. The <src> must be the path to a file or directory ... |
Read now
Unlock full access