aboutsummaryrefslogtreecommitdiff
path: root/server/Dockerfile
blob: a5ac0d975506f53d13f72a6940f65d879a836ade (plain)
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
FROM python:3.6-slim
WORKDIR /opt/app

COPY requirements.txt ./requirements.txt
RUN \
    # Install ffmpeg
    apt-get -yqq update && \
    apt-get -yq install --no-install-recommends ffmpeg && \
    rm -rf /var/lib/apt/lists/* && \
    # Install waitress
    pip3 install --no-cache-dir waitress && \
    # Install app requirements
    pip3 install --no-cache-dir -r ./requirements.txt

COPY ./ /opt/app/

ARG PUID=1000
ARG PGID=1000
RUN \
    # Set users
    mkdir -p /opt/app /data && \
    groupadd -g ${PGID} app && \
    useradd -d /opt/app -M -c '' -g app -r -u ${PUID} app && \
    chown -R app:app /opt/app /data
USER app

ENV PORT=6666
EXPOSE ${PORT}
VOLUME ["/data/"]
CMD ["/opt/app/docker-start.sh"]

© 2015 - 2026 Jakob L. Kreuze