dmsquash-live/apply-live-updates.sh: needs 'find'
also add /run/initramfs/live/updates as a directory, where to pull the updates from https://bugzilla.redhat.com/show_bug.cgi?id=1213736master
parent
437dad70e9
commit
4851deca54
|
@ -1,11 +1,13 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
if [ -b /dev/mapper/live-rw ] && [ -d /updates ]; then
|
if [ -b /dev/mapper/live-rw ] && [ -d /run/initramfs/live/updates -o -d /updates ]; then
|
||||||
info "Applying updates to live image..."
|
info "Applying updates to live image..."
|
||||||
mount -o bind /run $NEWROOT/run
|
mount -o bind /run $NEWROOT/run
|
||||||
# avoid overwriting symlinks (e.g. /lib -> /usr/lib) with directories
|
# avoid overwriting symlinks (e.g. /lib -> /usr/lib) with directories
|
||||||
|
for d in /updates /run/initramfs/live/updates; do
|
||||||
|
[ -d "$d" ] || continue
|
||||||
(
|
(
|
||||||
cd /updates
|
cd $d
|
||||||
find . -depth -type d | while read dir; do
|
find . -depth -type d | while read dir; do
|
||||||
mkdir -p "$NEWROOT/$dir"
|
mkdir -p "$NEWROOT/$dir"
|
||||||
done
|
done
|
||||||
|
@ -13,5 +15,6 @@ if [ -b /dev/mapper/live-rw ] && [ -d /updates ]; then
|
||||||
cp -a "$file" "$NEWROOT/$file"
|
cp -a "$file" "$NEWROOT/$file"
|
||||||
done
|
done
|
||||||
)
|
)
|
||||||
|
done
|
||||||
umount $NEWROOT/run
|
umount $NEWROOT/run
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -22,7 +22,7 @@ installkernel() {
|
||||||
|
|
||||||
# called by dracut
|
# called by dracut
|
||||||
install() {
|
install() {
|
||||||
inst_multiple umount dmsetup blkid dd losetup grep blockdev
|
inst_multiple umount dmsetup blkid dd losetup grep blockdev find
|
||||||
inst_multiple -o checkisomd5
|
inst_multiple -o checkisomd5
|
||||||
inst_hook cmdline 30 "$moddir/parse-dmsquash-live.sh"
|
inst_hook cmdline 30 "$moddir/parse-dmsquash-live.sh"
|
||||||
inst_hook cmdline 31 "$moddir/parse-iso-scan.sh"
|
inst_hook cmdline 31 "$moddir/parse-iso-scan.sh"
|
||||||
|
|
Loading…
Reference in New Issue