[ -n "$TUNE2FS" ] || TUNE2FS='tune2fs -c0 -i0'
[ -n "$UPGRADE_SYSTEM" ] || UPGRADE_SYSTEM='yes'
[ -n "$VMSIZE" ] || VMSIZE="2G"
[ -n "$TUNE2FS" ] || TUNE2FS='tune2fs -c0 -i0'
[ -n "$UPGRADE_SYSTEM" ] || UPGRADE_SYSTEM='yes'
[ -n "$VMSIZE" ] || VMSIZE="2G"
if ! mount "${TARGET}" "${MNTPOINT}" ; then
eerror "Error: Mounting ${TARGET} failed, can not continue." ; eend 1
if ! mount "${TARGET}" "${MNTPOINT}" ; then
eerror "Error: Mounting ${TARGET} failed, can not continue." ; eend 1
umount "${MNTPOINT}"
kpartx -d "${ORIG_TARGET}" >/dev/null
# Workaround for a bug in kpartx which doesn't clean up properly,
umount "${MNTPOINT}"
kpartx -d "${ORIG_TARGET}" >/dev/null
# Workaround for a bug in kpartx which doesn't clean up properly,
for i in format_efi_partition prepare_vm mkfs tunefs \
mount_target mountpoint_to_blockdevice debootstrap_system \
preparechroot execute_pre_scripts chrootscript execute_post_scripts \
for i in format_efi_partition prepare_vm mkfs tunefs \
mount_target mountpoint_to_blockdevice debootstrap_system \
preparechroot execute_pre_scripts chrootscript execute_post_scripts \