Dont try to unmount if were not using tmpfs
I regularly see users report that their build fails because this unmount line reports an error. Even though we dont bail here because of the || true, as a user it is hard to distinguish this from an error. Change-Id: Ic43f4fb24c53c58329fdf501bba6ba14024ec2aa
This commit is contained in:
parent
100959de8d
commit
f06e3fdb01
@ -172,7 +172,9 @@ function mount_qcow_image() {
|
||||
function cleanup_dirs () {
|
||||
sudo rm -rf $TMP_BUILD_DIR/built
|
||||
sudo rm -rf $TMP_BUILD_DIR/mnt
|
||||
sudo umount -f $TMP_BUILD_DIR $TMP_IMAGE_DIR || true
|
||||
if tmpfs_check ; then
|
||||
sudo umount -f $TMP_BUILD_DIR $TMP_IMAGE_DIR || true
|
||||
fi
|
||||
rm -rf --one-file-system $TMP_BUILD_DIR $TMP_IMAGE_DIR
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user