Remove the raw VM image if not requested at build time.

This commit is contained in:
parazyd 2020-11-13 11:21:31 +01:00
parent aedf124832
commit 9a1874d072
No known key found for this signature in database
GPG Key ID: 6B636BF0493EE747
1 changed files with 4 additions and 0 deletions

View File

@ -90,6 +90,10 @@ vm_pack_dist()
$_xzcomp "${image_name}.vdi" || { zerr; return 1; }
fi
if [[ "$imageformat" != raw ]]; then
rm -f "${image_name}.img"
fi
act "Calculating sha256 checksums"
silly
sha256sum "${image_name}.${_rsuffix}" > "${image_name}.${_rsuffix}.sha256"