Last active
October 7, 2022 18:19
-
-
Save ashish-mj/6f1cafaf0a05319f4bb16b464d787504 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a sample Dockerfile | |
# set base image python:3.8-slim-buster | |
FROM python:3.8-slim-buster | |
# set working directory as app | |
WORKDIR /app | |
# copy requirements.txt file from local (source) to file structure of container (destination) | |
COPY requirements.txt requirements.txt | |
# Install the requirements specified in file using RUN | |
RUN pip3 install -r requirements.txt | |
# copy all items in current local directory (source) to current container directory (destination) | |
COPY . . | |
# command to run when image is executed inside a container | |
CMD [ "python3", "app.py" ] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment