Intro to Building Container Images with Dockerfiles
The basics
Let’s start building container images.
Introducing Dockerfiles
A Dockerfile is simply a plain text file full of instructions. We pass a Dockerfile to the docker image build
command to assemble a container image.
FROM alpine:latest
LABEL maintainer=”Russ McKendrick <russ@mckendrick.io>”
LABEL description=”This example Dockerfile installs NGINX.”
RUN apk add --update nginx && \
rm -rf /var/cache/apk/* && \
mkdir -p /tmp/nginx/…