From 4fcd0eaf2fcb8e9fd2979bec500f047b422526fc Mon Sep 17 00:00:00 2001 From: Oleg Kalachev Date: Tue, 16 Apr 2024 04:06:30 +0300 Subject: [PATCH] Cleanup apt including all caches in the end of the build --- builder/image-validate.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/builder/image-validate.sh b/builder/image-validate.sh index c41188284..4cb8ec884 100755 --- a/builder/image-validate.sh +++ b/builder/image-validate.sh @@ -35,5 +35,10 @@ echo "Largest packages installed" sudo -E sh -c 'apt-get install -y debian-goodies' dpigs -H -n 100 +echo "Cleanup apt" +apt-get autoremove --purge -y +apt-get clean +rm -rf /var/cache/apt/* + echo "Move /etc/ld.so.preload back to its original position" mv /etc/ld.so.preload.disabled-for-build /etc/ld.so.preload