From c85902862726fcd31c2530f0e4d4cc52b24099e0 Mon Sep 17 00:00:00 2001 From: nfel Date: Tue, 4 Aug 2026 21:50:52 +0330 Subject: [PATCH] Bootstrap pip via ensurepip to install uv manager ensurepip -> pip install uv (package manager) -> uv sync. Uses python -m pip so no system pip CLI is needed. Co-authored-by: Qwen-Coder --- Dockerfile | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 1b81cf5..75c3791 100644 --- a/Dockerfile +++ b/Dockerfile @@ -67,12 +67,11 @@ WORKDIR /app # Copy manifests + lockfile first (stable cache layer) COPY pyproject.toml uv.lock* ./ -# Install uv, then build deps natively so the venv targets this image's Python -# (Playwright Noble ships Python but not uv or pip) -RUN mkdir -p /root/.local/bin \ - && curl -LsSf https://astral.sh/uv/install.sh | UV_INSTALL_DIR=/root/.local sh \ - && /root/.local/bin/uv sync --frozen --no-dev --no-install-project \ - && ln -sf /root/.local/bin/uv /usr/local/bin/uv +# Install deps natively so the venv targets this image's Python +# (Playwright Noble ships Python but not pip/uv in PATH) +RUN python -m ensurepip --upgrade \ + && python -m pip install --no-cache-dir --break-system-packages uv==0.11.31 \ + && uv sync --frozen --no-dev --no-install-project # Copy app code (busts cache on code changes, not deps) COPY . .