-
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile
24 lines (18 loc) · 872 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# The slim version of python is smaller than the Alpine version when using pandas
# and related libraries.
FROM python:3.7-slim
# Designate the working directory that code will reside at and be run from.
WORKDIR /app
# Copy the requirements now instead of re-copying after each source alteration
COPY requirements.txt /app
# Install the dependencies for the project.
# If the requirements don't change, the dependencies won't need to be re-installed.
RUN pip install -r requirements.txt
# Copy all files not listed in .dockerignore to the working directory.
COPY . /app
# Create an empty directory to save simulations to.
RUN mkdir -p simulations/
# Since the scripts are run in python, the 'python' entrypoint should be used to
# easily call the run script and parameters can be added at the end of the Docker
# command.
ENTRYPOINT ["python", "./run-simulator.py"]