07. Running Dockerfiles

Running Dockerfiles

ND9991 C04 L02 A06 Running Dockerfiles

You can find Noah's code here, within the demos subdirectory. Note that he has begun filling out the Dockerfile and run_docker.sh files in the video.

Docker Cheat Sheet

  • Use docker image ls to see all of your created Docker images
  • docker run -it {image name} bash ran Noah's Docker image

Here is a quick Docker cheat sheet for your reference: LINK

Noah's Dockerfile

Below is Noah's Dockerfile for your reference:

FROM python:3.7.3-stretch

# Working Directory
WORKDIR /app

# Copy source code to working directory
COPY . app.py /app/

# Install packages from requirements.txt
# hadolint ignore=DL3013
RUN pip install --upgrade pip &&\
    pip install --trusted-host pypi.python.org -r requirements.txt

Dockerfiles

What is FROM in a Dockerfile?

SOLUTION: A directive to load code