Skip to content

Instantly share code, notes, and snippets.

Last active Jun 12, 2022
What would you like to do?
Dockerfile [docker in a nutshell]
# use ubuntu as a base image
FROM ubuntu
# add custom label
LABEL ARTICLE_NAME="docker in a nutshell"
# add environment variable
# copy src directory from build context to my-app in container
COPY /src /my-app
# make my-app default directory for the upcoming commands
WORKDIR /my-app
# print contents
CMD ["ls", "-l"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment