-
-
Notifications
You must be signed in to change notification settings - Fork 609
/
release.dockerfile
45 lines (34 loc) · 1.04 KB
/
release.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
41
42
43
44
45
FROM python:3.11-slim AS builder
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC \
apt-get install -y --no-install-recommends \
build-essential \
&& rm -rf /var/lib/apt/lists/* \
&& apt-get clean
RUN python -m pip install --upgrade pip
RUN python -m pip install --upgrade libsass
FROM python:3.11-slim AS release
COPY --from=builder /usr/local/lib/python3.11/site-packages /usr/local/lib/python3.11/site-packages
ARG VERSION
LABEL maintainer="Zauberzeug GmbH <info@zauberzeug.com>"
RUN python -m pip install --upgrade pip
RUN python -m pip install \
nicegui[plotly,matplotlib]==$VERSION \
docutils \
isort \
itsdangerous \
pytest \
requests \
latex2mathml \
selenium
WORKDIR /app
COPY main.py README.md prometheus.py ./
COPY examples ./examples
COPY website ./website
RUN mkdir /resources
COPY docker-entrypoint.sh /resources
RUN chmod 777 /resources/docker-entrypoint.sh
EXPOSE 8080
ENV PYTHONUNBUFFERED=True
ENTRYPOINT ["/resources/docker-entrypoint.sh"]
CMD ["python", "main.py"]