Files
pypilot/Dockerfile
Luke Tainton 6600907e67
All checks were successful
Conventional Commit / Validate PR Title (pull_request) Successful in 2s
CI / ci (pull_request) Successful in 27s
fix(docker): update Python version in Dockerfile and adjust user permissions
Co-authored-by: Copilot <copilot@github.com>
2026-04-17 19:45:21 +01:00

31 lines
740 B
Docker

FROM python:3.14-slim
LABEL maintainer="Luke Tainton <luke@tainton.uk>"
LABEL org.opencontainers.image.source="https://github.com/luketainton/pypilot"
USER root
RUN useradd -r -s /sbin/nologin -M user
ENV PYTHONPATH="/run:/usr/local/lib/python3.14/lib-dynload:/usr/local/lib/python3.14/site-packages:/usr/local/lib/python3.14"
WORKDIR /run
RUN mkdir -p /.local && \
chmod -R 777 /.local && \
pip install --no-cache-dir -U pip uv==0.5.14
COPY pyproject.toml /run/pyproject.toml
COPY uv.lock /run/uv.lock
# needed for PDM build
COPY README.md /run/README.md
RUN uv sync --frozen
ENTRYPOINT ["python3", "-B", "-m", "app.main"]
ARG version="dev"
ENV APP_VERSION=$version
COPY app /run/app
RUN chown -R user:user /run
USER user