diff options
author | Erich Eckner <git@eckner.net> | 2019-06-16 15:04:56 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2019-08-20 09:00:45 +0200 |
commit | 15d32ea2d82aea7975bcdd223266ba3a3befe26c (patch) | |
tree | 8a88b50d0408fccd96c679c6197d6db573729355 | |
parent | bc4b38164eaecced47dc7c3896a8af7a6cbe1eae (diff) | |
download | devtools32-15d32ea2d82aea7975bcdd223266ba3a3befe26c.tar.xz |
archbuild.in: umount -l left-over mounts inside the to-be-deleted chrootv20190820
-rw-r--r-- | archbuild.in | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/archbuild.in b/archbuild.in index aed79f3..a6884a6 100644 --- a/archbuild.in +++ b/archbuild.in @@ -76,6 +76,12 @@ if ${clean_first} || [[ ! -d "${chroots}/${repo}-${arch}" ]]; then lock 9 "$copy.lock" "Locking chroot copy '%s'" "$copy" subvolume_delete_recursive "${copy}" + find "${copy}" \ + -mindepth 1 \ + -type d \ + -exec mountpoint -q {} \; \ + -prune \ + -exec umount -l {} \; rm -rf --one-file-system "${copy}" done lock_close 9 |