11FROM dockerhub.apps.cp.meteoswiss.ch/mch/python-3.10 AS builder
2+ ARG VERSION
3+ LABEL ch.meteoswiss.project=pyflexplot-${VERSION}
24
35COPY poetry.lock /src/app-root/
46COPY pyproject.toml /src/app-root/
@@ -9,10 +11,12 @@ RUN cd /src/app-root \
911 # we need to build the wheel in order to install the binary python \
1012 # package that uses click to parse the command arguments
1113 && poetry build --format wheel \
12- && poetry export --without-hashes - o requirements.txt \
13- && poetry export --without-hashes -- dev -o requirements_dev.txt
14+ && poetry export -o requirements.txt \
15+ && poetry export --dev -o requirements_dev.txt
1416
1517FROM dockerhub.apps.cp.meteoswiss.ch/mch/python-3.10:latest-slim AS base
18+ ARG VERSION
19+ LABEL ch.meteoswiss.project=pyflexplot-${VERSION}
1620
1721COPY --from=builder /src/app-root/dist/*.whl /src/app-root/
1822COPY --from=builder /src/app-root/requirements.txt /src/app-root/
@@ -24,24 +28,18 @@ RUN pip install -r /src/app-root/requirements.txt \
2428WORKDIR /src/app-root
2529
2630FROM base AS runner
31+ ARG VERSION
32+ LABEL ch.meteoswiss.project=pyflexplot-${VERSION}
2733
2834RUN mkdir /src/app-root/data /src/app-root/output
2935
30- ENV HTTPS_PROXY=\
31- HTTP_PROXY=\
32- http_proxy=\
33- https_proxy=\
34- NO_PROXY=\
35- no_proxy=
36-
3736ENTRYPOINT ["pyflexplot" ]
3837
3938FROM base AS tester
39+ ARG VERSION
40+ LABEL ch.meteoswiss.project=pyflexplot-${VERSION}
4041
4142COPY --from=builder /src/app-root/requirements_dev.txt /src/app-root/requirements_dev.txt
4243RUN pip install -r /src/app-root/requirements_dev.txt
4344
4445COPY tests /src/app-root/tests
45- COPY pyproject.toml test_ci.sh /src/app-root/
46-
47- CMD ["/bin/bash" , "-c" , "source /src/app-root/test_ci.sh && run_ci_tools" ]
0 commit comments