This repository has been archived by the owner on Nov 20, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
50 lines (40 loc) · 1.77 KB
/
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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
###################################################################
# Script Name : "DOCKERFILE"
# Description : Builds an image for the door2door mi challenge
# Args :
# Author : Floris Remmen
# Email : [email protected]
# Date : "22 September 2020"
###################################################################
# Intiia
FROM python:3.8
ADD requirements.txt /tmp/requirements.txt
# Necessary for using shapely and other geoprocessing libraries.
# From : https://gist.github.com/johnniehard/90a7f4fc1b0701360f67ba77b9b50c7a
RUN apt-get update && \
apt-get install -y \
build-essential \
make \
gcc \
locales \
libgdal20 libgdal-dev && \
python -m pip install numpy cython --no-binary numpy,cython && \
python -m pip install \
"rasterio>=1.0a12" fiona shapely \
--pre --no-binary rasterio,fiona,shapely && \
python -m pip install -r /tmp/requirements.txt && \
python -m pip uninstall -y cython && \
rm -r /root/.cache/pip && \
apt-get remove -y --purge libgdal-dev make gcc build-essential && \
apt-get autoremove -y && \
rm -rf /var/lib/apt/lists/*
RUN dpkg-reconfigure locales && \
locale-gen C.UTF-8 && \
/usr/sbin/update-locale LANG=C.UTF-8
ENV LC_ALL C.UTF-8
# Copy the project to the root of the container
COPY . /app
WORKDIR /app
# Start the application.
ENTRYPOINT [ "python" ]
CMD [ "app.py" ]