-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
33 lines (26 loc) · 891 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
25
26
27
28
29
30
31
32
33
FROM debian:9
LABEL maintainer="Daniel Kertesz <[email protected]>"
RUN apt -q update && \
env DEBIAN_FRONTEND=noninteractive apt upgrade -y && \
env DEBIAN_FRONTEND=noninteractive apt install -qy --no-install-recommends \
python3 \
python3-pip \
python3-venv \
git-core
# Add "libev4" for bjoern
RUN mkdir -p /app && \
chown www-data:www-data /app
USER www-data
ADD --chown=www-data:www-data . /app/src
WORKDIR /app/src
RUN python3 -m venv /app/venv && \
/app/venv/bin/pip3 install --no-cache-dir -qU pip && \
/app/venv/bin/pip3 install --no-cache-dir -e ".[mysql]"
ENV FLASK_APP="qstode.main:create_app()" \
APP_CONFIG=/app/src/config.py \
FLASK_ENV=development \
LC_ALL=C.UTF-8 \
LANG=C.UTF-8
EXPOSE 5000
ENTRYPOINT ["/app/venv/bin/python", "-m", "flask"]
CMD ["run", "-h", "0.0.0.0"]