# remove now useless apt cache {{{
remove_apt_cache() {
- apt-get clean
+ if [ "$RM_APTCACHE" = 'yes' ] ; then
+ echo "Cleaning apt cache."
+ apt-get clean
+ else
+ echo "Not cleaning apt cache as \$RM_APTCACHE is unset."
+ fi
}
# }}}
# use /usr/share/zoneinfo/$TIMEZONE for /etc/localtime
TIMEZONE='Europe/Vienna'
+# remove apt cache in chroot after installation of packages finished?
+RM_APTCACHE='yes'
+
# generate initrd via update-initramfs?
INITRD='yes'
breaks the way grml-debootstrap used to work. Instead:
* Introduce option --nopackages to skip installation of packages
defined in /etc/debootstrap/packages.
+ * Support config variable RM_APTCACHE to allow disabling removal
+ of apt-cache. Thanks for the idea and initial patch, Tong Sun.
+ [Closes: issue805]
- -- Michael Prokop <mika@grml.org> Mon, 22 Feb 2010 23:33:54 +0100
+ -- Michael Prokop <mika@grml.org> Mon, 22 Feb 2010 23:46:13 +0100
grml-debootstrap (0.33) unstable; urgency=low
[ -n "$ROOTPASSWORD" ] && echo "ROOTPASSWORD=$ROOTPASSWORD" >> $CHROOT_VARIABLES
[ -n "$TARGET" ] && echo "TARGET=$TARGET" >> $CHROOT_VARIABLES
[ -n "$TARGET_UUID" ] && echo "TARGET_UUID=$TARGET_UUID" >> $CHROOT_VARIABLES
+ [ -n "$RM_APTCACHE" ] && echo "RM_APTCACHE=$RM_APTCACHE" >> $CHROOT_VARIABLES
cp $VERBOSE $CONFFILES/chroot-script $MNTPOINT/bin/chroot-script
chmod 755 $MNTPOINT/bin/chroot-script