@@ -58,6 +58,8 @@ RUN --mount=type=cache,id=apt-lib-cache-${TARGETARCH},sharing=private,target=/va
58
58
apt-get -y autoclean && \
59
59
rm -f /var/cache/debconf/*.dat-old
60
60
61
+ FROM ghcr.io/astral-sh/uv:latest AS uv-binaries
62
+
61
63
FROM alpine:${ALPINE_VERSION} AS openresty-debian
62
64
ARG TARGETARCH
63
65
ARG DEBIAN_VERSION
@@ -279,6 +281,9 @@ RUN set -eu ; \
279
281
FROM scratch AS s6-overlay
280
282
COPY --from=s6-overlay-extracted /s6-overlay-rootfs /
281
283
284
+ FROM tubesync-base AS tubesync-uv
285
+ COPY --from=uv-binaries /uv /uvx /usr/local/bin/
286
+
282
287
FROM tubesync-base AS tubesync-openresty
283
288
284
289
COPY --from=openresty-debian \
@@ -341,12 +346,10 @@ RUN --mount=type=cache,id=apt-lib-cache-${TARGETARCH},sharing=private,target=/va
341
346
libmariadb3 \
342
347
libpq5 \
343
348
libwebp7 \
344
- pipenv \
345
349
pkgconf \
346
350
python3 \
347
351
python3-libsass \
348
352
python3-socks \
349
- python3-wheel \
350
353
curl \
351
354
less \
352
355
&& \
@@ -389,9 +392,11 @@ ARG YTDLP_DATE
389
392
390
393
# Set up the app
391
394
RUN --mount=type=tmpfs,target=/cache \
395
+ --mount=type=cache,id=uv-cache,sharing=locked,target=/cache/uv \
392
396
--mount=type=cache,id=pipenv-cache,sharing=locked,target=/cache/pipenv \
393
397
--mount=type=cache,id=apt-lib-cache-${TARGETARCH},sharing=private,target=/var/lib/apt \
394
398
--mount=type=cache,id=apt-cache-cache,sharing=private,target=/var/cache/apt \
399
+ --mount=type=bind,source=/uv,target=/usr/local/bin/uv,from=uv-binaries \
395
400
--mount=type=bind,source=Pipfile,target=/app/Pipfile \
396
401
set -x && \
397
402
apt-get update && \
@@ -406,7 +411,6 @@ RUN --mount=type=tmpfs,target=/cache \
406
411
make \
407
412
postgresql-common \
408
413
python3-dev \
409
- python3-pip \
410
414
zlib1g-dev \
411
415
&& \
412
416
# Install non-distro packages
@@ -415,6 +419,7 @@ RUN --mount=type=tmpfs,target=/cache \
415
419
XDG_CACHE_HOME='/cache' \
416
420
PIPENV_VERBOSITY=64 \
417
421
PYTHONPYCACHEPREFIX=/cache/pycache \
422
+ uv tool run --no-config --no-progress --no-managed-python -- \
418
423
pipenv install --system --skip-lock && \
419
424
# remove the getpot_bgutil_script plugin
420
425
find /usr/local/lib \
@@ -433,7 +438,6 @@ RUN --mount=type=tmpfs,target=/cache \
433
438
make \
434
439
postgresql-common \
435
440
python3-dev \
436
- python3-pip \
437
441
zlib1g-dev \
438
442
&& \
439
443
apt-get -y autopurge && \
0 commit comments