Merge pull request #792 from tcely/patch-6

Clean up `__pycache__` directories
This commit is contained in:
meeb 2025-03-01 08:28:08 +11:00 committed by GitHub
commit 6cfd860b10
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -297,6 +297,9 @@ RUN --mount=type=tmpfs,target=/cache \
--mount=type=cache,id=apt-cache-cache,sharing=locked,target=/var/cache/apt \
--mount=type=bind,source=Pipfile,target=/app/Pipfile \
set -x && \
# Remove __pycache__ directories from the image
PYTHONPYCACHEPREFIX=/cache/pycache && \
export PYTHONPYCACHEPREFIX && \
# Update from the network and keep cache
rm -f /etc/apt/apt.conf.d/docker-clean && \
apt-get update && \