add kexec service
This commit is contained in:
parent
3dc400e459
commit
4fccd6414b
14
install.sh
14
install.sh
|
@ -269,6 +269,20 @@ ConditionPathExists=/installer/script.sh
|
|||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/installer/script.sh
|
||||
EOF
|
||||
|
||||
mkdir -p ${unitdir}/sysinit.target.wants
|
||||
ln -s ../arch-kernel.service ${unitdir}/sysinit.target.wants
|
||||
cat > ${unitdir}/arch-kernel.service <<EOF
|
||||
[Unit]
|
||||
Description=Reboots into arch kernel
|
||||
ConditionKernelCommandLine=!archkernel
|
||||
DefaultDependencies=no
|
||||
Before=local-fs-pre.target systemd-remount-fs.service
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/sbin/kexec /boot/vmlinuz-linux --initrd=/boot/initramfs-linux.img --reuse-cmdline --command-line=archkernel
|
||||
EOF
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue