2023-04-17 05:26:22 +02:00
|
|
|
FROM python:3-alpine
|
2023-12-15 13:11:40 +01:00
|
|
|
|
2023-12-15 23:21:56 +01:00
|
|
|
ARG USER_=admin
|
|
|
|
ARG UID_=1000
|
|
|
|
|
2023-04-17 05:26:22 +02:00
|
|
|
RUN apk add --no-cache --upgrade bash
|
2023-04-20 11:55:17 +02:00
|
|
|
|
|
|
|
ADD --chown=$UID_:$UID_ . /www
|
2023-04-17 05:26:22 +02:00
|
|
|
WORKDIR /www
|
|
|
|
|
|
|
|
RUN chmod +x start.sh
|
|
|
|
RUN set -e; \
|
|
|
|
apk add --no-cache --virtual .build-deps \
|
|
|
|
gcc \
|
|
|
|
libc-dev \
|
|
|
|
linux-headers \
|
|
|
|
; \
|
|
|
|
pip install -r requirements.txt; \
|
|
|
|
apk del .build-deps;
|
|
|
|
|
2023-12-15 23:21:56 +01:00
|
|
|
RUN adduser -S -D $USER_ -u $UID_
|
|
|
|
USER $USER_
|
2023-12-15 13:11:40 +01:00
|
|
|
|
2023-12-15 23:21:56 +01:00
|
|
|
ENTRYPOINT ["./start.sh"]
|