File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,27 +4,24 @@ ARG USERNAME=ContainerUser
44ARG PYTHONVERSION=3.11
55
66# ############################################################################################################
7- FROM python:${PYTHONVERSION} AS python-base
7+ FROM debian:bookworm AS python-base
88
9- ENV POETRY_VERSION=2.1.1
10- ENV POETRY_CACHE_DIR=/var/cache/poetry \
11- POETRY_HOME=/opt/poetry \
12- PATH=/opt/poetry/bin:${PATH}\
13- PYTHONFAULTHANDLER=1 \
9+ ENV PYTHONFAULTHANDLER=1 \
1410 PYTHONUNBUFFERED=1 \
1511 PIP_CACHE_DIR=/var/cache/pip
16- RUN mkdir -p $PIP_CACHE_DIR $POETRY_CACHE_DIR
12+ RUN mkdir -p $PIP_CACHE_DIR
1713
18- # ############################################################################################################
19- FROM python-base AS devcontainer
2014ARG USERNAME
2115LABEL org.opencontainers.image.source=https://github.com/OpenJKSoftware/python-devcontainer
2216
2317# Install uv
2418COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
2519ENV UV_CACHE_DIR=/var/cache/uv \
26- UV_LINK_MODE=copy
27- RUN mkdir -p $UV_CACHE_DIR
20+ UV_PYTHON_CACHE_DIR=/var/cache/uv/python \
21+ UV_LINK_MODE=copy \
22+ UV_COMPILE_BYTECODE=1
23+ RUN set -x; mkdir -p $UV_CACHE_DIR && mkdir -p $UV_PYTHON_CACHE_DIR
24+ RUN --mount=type=cache,target=/var/cache uv python install ${PYTHONVERSION} --install-deps --default
2825
2926# Install Base Reqs
3027COPY scripts/install_base_deps.sh /tmp/
You can’t perform that action at this time.
0 commit comments