Support Fedora CoreOS (#1727)

This commit is contained in:
longpanda 2022-07-12 12:13:24 +08:00
parent e46e24dde7
commit da35a99f7c
2 changed files with 9 additions and 1 deletions

View File

@ -128,6 +128,12 @@ if [ -e /usr/sbin/anaconda-diskroot ]; then
$SED 's/^mount $dev $repodir/mount -oro $dev $repodir/' -i /usr/sbin/anaconda-diskroot
fi
#For Fedora CoreOS
if $GREP -i -q 'fedora.*coreos' /etc/os-release; then
$SED "s#isosrc=.*#isosrc=/dev/mapper/ventoy#" -i /lib/systemd/system-generators/live-generator
cp -a $VTOY_PATH/hook/rhel7/ventoy-make-link.sh /lib/dracut/hooks/pre-mount/99-ventoy-premount-mklink.sh
fi
if [ -f $VTOY_PATH/autoinstall ]; then
cp -a $VTOY_PATH/hook/rhel7/ventoy-autoexp.sh /lib/dracut/hooks/pre-mount/99-ventoy-autoexp.sh
fi

View File

@ -381,7 +381,9 @@ function distro_specify_initrd_file_phase2 {
vt_linux_specify_initrd_file /sysresccd/boot/i686/sysresccd.img
elif [ -f (loop)/boot/full.cz ]; then
vt_linux_specify_initrd_file /boot/full.cz
elif [ -f (loop)/images/pxeboot/initrd.img ]; then
vt_linux_specify_initrd_file /images/pxeboot/initrd.img
fi
}