mirror of
https://git.launchpad.net/livecd-rootfs
synced 2025-06-08 16:41:35 +00:00
Merge lp:~cjwatson/livecd-rootfs/recursive-mount-dev
This commit is contained in:
commit
148fa39a8e
5
debian/changelog
vendored
5
debian/changelog
vendored
@ -3,6 +3,11 @@ livecd-rootfs (2.453) UNRELEASED; urgency=medium
|
|||||||
[ Chris Glass ]
|
[ Chris Glass ]
|
||||||
* Create vagrant user for vagrant image, per upstream requirements.
|
* Create vagrant user for vagrant image, per upstream requirements.
|
||||||
|
|
||||||
|
[ Colin Watson ]
|
||||||
|
* Mount and unmount /dev recursively, to cope with setups where there are
|
||||||
|
interesting bind-mounts under /dev (e.g. loop devices bind-mounted by
|
||||||
|
LXD). LP: #1716465.
|
||||||
|
|
||||||
-- Adam Conrad <adconrad@ubuntu.com> Fri, 01 Sep 2017 10:53:46 -0600
|
-- Adam Conrad <adconrad@ubuntu.com> Fri, 01 Sep 2017 10:53:46 -0600
|
||||||
|
|
||||||
livecd-rootfs (2.452) artful; urgency=medium
|
livecd-rootfs (2.452) artful; urgency=medium
|
||||||
|
@ -79,8 +79,7 @@ mount_image() {
|
|||||||
setup_mountpoint() {
|
setup_mountpoint() {
|
||||||
local mountpoint="$1"
|
local mountpoint="$1"
|
||||||
|
|
||||||
mount --bind /dev "$mountpoint/dev"
|
mount --rbind /dev "$mountpoint/dev"
|
||||||
mount devpts-live -t proc "$mountpoint/dev/pts"
|
|
||||||
mount proc-live -t proc "$mountpoint/proc"
|
mount proc-live -t proc "$mountpoint/proc"
|
||||||
mount sysfs-live -t sysfs "$mountpoint/sys"
|
mount sysfs-live -t sysfs "$mountpoint/sys"
|
||||||
mount -t tmpfs none "$mountpoint/tmp"
|
mount -t tmpfs none "$mountpoint/tmp"
|
||||||
@ -141,11 +140,7 @@ umount_settle() {
|
|||||||
umount_partition() {
|
umount_partition() {
|
||||||
local mountpoint=${1}
|
local mountpoint=${1}
|
||||||
mv resolv.conf.tmp "$mountpoint/etc/resolv.conf"
|
mv resolv.conf.tmp "$mountpoint/etc/resolv.conf"
|
||||||
for submnt in proc sys dev/pts dev tmp;
|
umount -R $mountpoint
|
||||||
do
|
|
||||||
umount $mountpoint/$submnt
|
|
||||||
done
|
|
||||||
umount $mountpoint
|
|
||||||
udevadm settle
|
udevadm settle
|
||||||
|
|
||||||
if [ -n "${rootfs_dev_mapper}" -a -b "${rootfs_dev_mapper}" ]; then
|
if [ -n "${rootfs_dev_mapper}" -a -b "${rootfs_dev_mapper}" ]; then
|
||||||
|
@ -39,8 +39,7 @@ chroot binary/boot/squashfs.dir dpkg-divert --remove --local --rename /usr/sbin/
|
|||||||
mv resolv.conf.tmp "binary/boot/squashfs.dir/etc/resolv.conf"
|
mv resolv.conf.tmp "binary/boot/squashfs.dir/etc/resolv.conf"
|
||||||
umount "binary/boot/squashfs.dir/proc"
|
umount "binary/boot/squashfs.dir/proc"
|
||||||
umount "binary/boot/squashfs.dir/sys"
|
umount "binary/boot/squashfs.dir/sys"
|
||||||
umount "binary/boot/squashfs.dir/dev/pts"
|
umount -R "binary/boot/squashfs.dir/dev"
|
||||||
umount "binary/boot/squashfs.dir/dev"
|
|
||||||
umount "binary/boot/squashfs.dir/tmp"
|
umount "binary/boot/squashfs.dir/tmp"
|
||||||
|
|
||||||
squashfs_f="${PWD}/livecd.ubuntu-cpc.squashfs"
|
squashfs_f="${PWD}/livecd.ubuntu-cpc.squashfs"
|
||||||
|
@ -155,8 +155,7 @@ umount "$SQUASH_ROOT"
|
|||||||
# Then we can start unmounting the "real" root:
|
# Then we can start unmounting the "real" root:
|
||||||
umount "binary/boot/squashfs.dir/proc"
|
umount "binary/boot/squashfs.dir/proc"
|
||||||
umount "binary/boot/squashfs.dir/sys"
|
umount "binary/boot/squashfs.dir/sys"
|
||||||
umount "binary/boot/squashfs.dir/dev/pts"
|
umount -R "binary/boot/squashfs.dir/dev"
|
||||||
umount "binary/boot/squashfs.dir/dev"
|
|
||||||
umount "binary/boot/squashfs.dir/tmp"
|
umount "binary/boot/squashfs.dir/tmp"
|
||||||
|
|
||||||
squashfs_f="${PWD}/livecd.${PROJECT}.installer.squashfs"
|
squashfs_f="${PWD}/livecd.${PROJECT}.installer.squashfs"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user