]> git.ipfire.org Git - thirdparty/dracut.git/blobdiff - dracut-initramfs-restore.sh
travis: reshuffle tests
[thirdparty/dracut.git] / dracut-initramfs-restore.sh
index 0e6a1a88a76499e81ad7958ad26d956cae3294ef..9479480490487d251aaad3a397975f24957ba75c 100644 (file)
@@ -14,7 +14,7 @@ SKIP="$dracutbasedir/skipcpio"
 
 [[ -f /etc/machine-id ]] && read MACHINE_ID < /etc/machine-id
 
-mount -o ro /boot &>/dev/null
+mount -o ro /boot &>/dev/null || true
 
 if [[ $MACHINE_ID ]] && [[ -d /boot/${MACHINE_ID} || -L /boot/${MACHINE_ID} ]] ; then
     IMG="/boot/${MACHINE_ID}/${KERNEL_VERSION}/initrd"
@@ -31,6 +31,8 @@ elif $SKIP "$IMG" | xzcat | cpio -id --no-absolute-filenames --quiet >/dev/null;
     rm -f -- .need_shutdown
 elif $SKIP "$IMG" | lz4 -d -c | cpio -id --no-absolute-filenames --quiet >/dev/null; then
     rm -f -- .need_shutdown
+elif $SKIP "$IMG" | zstd -d -c | cpio -id --no-absolute-filenames --quiet >/dev/null; then
+    rm -f -- .need_shutdown
 else
     # something failed, so we clean up
     echo "Unpacking of $IMG to /run/initramfs failed" >&2