2018-06-19 22:54:07 +02:00
|
|
|
|
2022-07-16 19:29:30 +02:00
|
|
|
FROM python:3.9-alpine
|
2018-06-19 22:54:07 +02:00
|
|
|
|
2018-11-04 02:55:33 +01:00
|
|
|
ADD . /
|
2018-09-10 01:25:07 +02:00
|
|
|
RUN mkdir -p /var/matemat/db /var/matemat/upload \
|
2020-02-03 23:39:35 +01:00
|
|
|
&& chown 1000:0 -R /var/matemat/db /var/matemat/upload \
|
|
|
|
&& chmod g=u -R /var/matemat/db /var/matemat/upload \
|
2018-09-10 01:25:07 +02:00
|
|
|
&& apk --update add libmagic zlib jpeg zlib-dev jpeg-dev build-base \
|
2018-11-04 02:58:18 +01:00
|
|
|
&& pip3 install -e . \
|
2018-09-10 01:25:07 +02:00
|
|
|
&& apk del zlib-dev jpeg-dev build-base \
|
2018-11-04 02:55:33 +01:00
|
|
|
&& rm -rf /var/cache/apk /root/.cache/pip \
|
|
|
|
&& rm -rf /package
|
2018-06-19 22:54:07 +02:00
|
|
|
|
2020-02-03 23:39:35 +01:00
|
|
|
USER 1000
|
|
|
|
|
2018-07-15 00:07:25 +02:00
|
|
|
EXPOSE 80/tcp
|
2018-07-20 11:38:16 +02:00
|
|
|
CMD [ "/run.sh" ]
|