Dockerfile 633 Bytes
Newer Older
Florent Chehab's avatar
Florent Chehab committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# pull official base image
# Use of stretch instead of Alpine for faster install of python packages (especially pandas)
# Overall performance might be slightly better (with bigger image size obviously)
FROM python:3.7.2-slim-stretch

# set work directory
WORKDIR /usr/src/app

# runtime dependencies
# libpq-dev and gcc  is for psycopg2-binary
RUN apt-get update && apt-get install -y --no-install-recommends \
		libpq-dev \
		python3-dev \
		gcc \
		make \
	&& rm -rf /var/lib/apt/lists/*


# install dependencies
RUN pip install --upgrade pip
COPY requirements.txt /usr/src/app/requirements.txt
RUN pip install -r requirements.txt