Umount, not mount a 2nd time ...
This commit is contained in:
parent
919a725b04
commit
838a7171ba
1 changed files with 2 additions and 2 deletions
|
@ -25,7 +25,7 @@ rootfs_tmpdir=$(mktemp -d)
|
||||||
rootfs_url="http://dl-cdn.alpinelinux.org/alpine/v$MAJOR_VERSION/releases/x86_64/$IMAGE"
|
rootfs_url="http://dl-cdn.alpinelinux.org/alpine/v$MAJOR_VERSION/releases/x86_64/$IMAGE"
|
||||||
|
|
||||||
run_root () {
|
run_root () {
|
||||||
sudo chroot $rootfs_tmpdir
|
sudo chroot $rootfs_tmpdir /usr/bin/env \
|
||||||
PATH=/sbin:/bin:/usr/sbin:/usr/bin \
|
PATH=/sbin:/bin:/usr/sbin:/usr/bin \
|
||||||
/bin/sh -c "$*"
|
/bin/sh -c "$*"
|
||||||
}
|
}
|
||||||
|
@ -95,7 +95,7 @@ run_root grub-install --target=i386-pc ${DISK}
|
||||||
# Cleanup
|
# Cleanup
|
||||||
run_root rm -f /etc/resolv.conf
|
run_root rm -f /etc/resolv.conf
|
||||||
for dir in dev proc sys; do
|
for dir in dev proc sys; do
|
||||||
sudo mount --bind /${dir} ${rootfs_tmpdir}/${dir}
|
sudo umount ${rootfs_tmpdir}/${dir}
|
||||||
done
|
done
|
||||||
sudo umount $rootfs_tmpdir
|
sudo umount $rootfs_tmpdir
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue