refractor(mkimg): using fallback initramfs directly (#4)

This commit is contained in:
Felix Yan 2022-08-03 07:10:27 +03:00 committed by GitHub
parent 0f2e94e4b6
commit 1dd75aa50e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -100,14 +100,10 @@ default linux
label linux label linux
menu label Linux linux menu label Linux linux
kernel /boot/vmlinuz-linux kernel /boot/vmlinuz-linux
initrd /boot/initramfs-linux.img initrd /boot/initramfs-linux-fallback.img
append earlyprintk rw root=/dev/vda1 rootwait rootfstype=ext4 LANG=en_US.UTF-8 console=ttyS0 append earlyprintk rw root=/dev/vda1 rootwait rootfstype=ext4 LANG=en_US.UTF-8 console=ttyS0
EOF EOF
msg "Re-generate initramfs for QEMU..."
kver=$(sudo arch-chroot qcow2 pacman -Si linux | grep -Po '(?<=Version : ).*')
sudo arch-chroot qcow2 dracut --force --add "qemu qemu-net" /boot/initramfs-linux.img ${kver/.arch/-arch}
msg "Clean up..." msg "Clean up..."
msg2 "Clean up pacman package cache..." msg2 "Clean up pacman package cache..."
yes y | sudo pacman \ yes y | sudo pacman \