From deacb83ca7c581b58a1ff9026dd7d41d0c26f70d Mon Sep 17 00:00:00 2001 From: tcely Date: Sun, 25 May 2025 02:20:46 -0400 Subject: [PATCH] Install using `uv pip install` When `pipenv` installs it is using a virtual environment that `uv` created for it to run as a tool. --- Dockerfile | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 20ca321e..4b691f47 100644 --- a/Dockerfile +++ b/Dockerfile @@ -421,7 +421,21 @@ RUN --mount=type=tmpfs,target=/cache \ PIPENV_VERBOSITY=64 \ PYTHONPYCACHEPREFIX=/cache/pycache \ uv tool run --no-config --no-progress --no-managed-python -- \ - pipenv install --system --skip-lock && \ + pipenv lock && \ + HOME="/tmp/${HOME#/}" \ + XDG_CACHE_HOME='/cache' \ + PIPENV_VERBOSITY=1 \ + PYTHONPYCACHEPREFIX=/cache/pycache \ + uv tool run --no-config --no-progress --no-managed-python -- \ + pipenv requirements --from-pipfile --hash >| /cache/requirements.txt && \ + rm -v Pipfile.lock && \ + cat -v /cache/requirements.txt && \ + HOME="/tmp/${HOME#/}" \ + XDG_CACHE_HOME='/cache' \ + PYTHONPYCACHEPREFIX=/cache/pycache \ + uv --no-config --no-progress --no-managed-python \ + pip install --strict --system --break-system-packages \ + --requirements /cache/requirements.txt && \ # remove the getpot_bgutil_script plugin find /usr/local/lib \ -name 'getpot_bgutil_script.py' \