-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
40 lines (39 loc) · 1.36 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
#FROM python:3.7.2-stretch
FROM python:3.7-slim
EXPOSE 8000
ENV PYTHONUNBUFFERED 1
# Update pip
RUN /usr/local/bin/python -m pip install --upgrade pip
# Install libgeos-dev using apt
RUN apt-get update
#RUN apt-get install -y libgeos-dev
RUN apt-get install -y wget libgeos-dev libmariadb-dev gcc
#Angular dependencies
# RUN apt-get -y install curl
# RUN curl -sL https://deb.nodesource.com/setup_12.x
# RUN apt-get -y install nodejs
# Download basemap (without spamming stdout)
RUN wget -q --show-progress --progress=bar:force:noscroll -O basemap-1.2.2rel.tar.gz https://github.com/matplotlib/basemap/archive/v1.2.2rel.tar.gz
# Install packages (basemap needs to installed separetly after numpy and matplotlib for no errors)
COPY ./requirements.txt /requirements.txt
RUN pip install -r /requirements.txt
RUN pip install ///basemap-1.2.2rel.tar.gz
# Make folders
RUN mkdir -p /app/broker/out/data_in
RUN mkdir -p /app/broker/out/data_out
RUN mkdir -p /app/broker/processed
RUN mkdir -p /tmp/results
RUN chmod -R 777 /tmp/results/
RUN mkdir /pmedapp
RUN mkdir -p /static
COPY ./static/ /static/
COPY . /pmedapp/
# Setting up angular project
# RUN npm install -y -g @angular/cli
# WORKDIR /pmedapp/angular-frontend
# RUN npm install
# RUN ng build --prod --output-path ./static/angular-frontend/static/angular/ --output-hashing none
# RUN rm -rf node_modules
WORKDIR /pmedapp
# Start
CMD ./init.sh