diff --git a/Dockerfile b/Dockerfile index 60252c7..5dc7c5d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,15 +4,15 @@ ARG package=arcaflow_plugin_template_python # STAGE 1 -- Build module dependencies and run tests # The 'poetry' and 'coverage' modules are installed and verson-controlled in the # quay.io/arcalot/arcaflow-plugin-baseimage-python-buildbase image to limit drift -FROM quay.io/arcalot/arcaflow-plugin-baseimage-python-buildbase:0.1.0 as build +FROM quay.io/arcalot/arcaflow-plugin-baseimage-python-buildbase:0.2.0 as build ARG package COPY poetry.lock /app/ COPY pyproject.toml /app/ # Convert the dependencies from poetry to a static requirements.txt file -RUN python3.9 -m poetry install --without dev --no-root \ - && python3.9 -m poetry export -f requirements.txt --output requirements.txt --without-hashes +RUN python -m poetry install --without dev --no-root \ + && python -m poetry export -f requirements.txt --output requirements.txt --without-hashes COPY ${package}/ /app/${package} COPY tests /app/${package}/tests @@ -21,12 +21,12 @@ ENV PYTHONPATH /app/${package} WORKDIR /app/${package} # Run tests and return coverage analysis -RUN python3.9 -m coverage run tests/test_${package}.py \ - && python3.9 -m coverage html -d /htmlcov --omit=/usr/local/* +RUN python -m coverage run tests/test_${package}.py \ + && python -m coverage html -d /htmlcov --omit=/usr/local/* # STAGE 2 -- Build final plugin image -FROM quay.io/arcalot/arcaflow-plugin-baseimage-python-osbase:0.1.0 +FROM quay.io/arcalot/arcaflow-plugin-baseimage-python-osbase:0.2.0 ARG package COPY --from=build /app/requirements.txt /app/ @@ -36,11 +36,11 @@ COPY README.md /app/ COPY ${package}/ /app/${package} # Install all plugin dependencies from the generated requirements.txt file -RUN python3.9 -m pip install -r requirements.txt +RUN python -m pip install -r requirements.txt WORKDIR /app/${package} -ENTRYPOINT ["python3.9", "arcaflow_plugin_template_python.py"] +ENTRYPOINT ["python", "arcaflow_plugin_template_python.py"] CMD [] LABEL org.opencontainers.image.source="https://github.com/arcalot/arcaflow-plugin-template-python"