Skip to content

Commit

Permalink
Purge pip cache
Browse files Browse the repository at this point in the history
We don't really need to keep pip cache as we don't install more
packages with pip after the initial build.
It should reduce the size of the final image of about 50MB.
  • Loading branch information
elfosardo committed Aug 7, 2024
1 parent 81032e7 commit 64f112f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions prepare-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -104,5 +104,8 @@ if [[ -n "${PATCH_LIST:-}" ]]; then
fi
rm -f /bin/patch-image.sh

# purge pip cache
python3 -m pip cache purge

dnf clean all
rm -rf /var/cache/{yum,dnf}/*

0 comments on commit 64f112f

Please sign in to comment.