F15 fix: remove /sbin/init before copying over it
If it's a symlink, we'll copy the file into the symlink, and then we'll likely remove the target of the symlink (../bin/systemd) in cleanup, and then we have no init. Boo.
This commit is contained in:
parent
f5164d6460
commit
14cc34e1ee
@ -31,19 +31,20 @@ move etc/yum.repos.d etc/anaconda.repos.d
|
|||||||
## misc_tree_modifications()
|
## misc_tree_modifications()
|
||||||
%if int(product.version) > 15:
|
%if int(product.version) > 15:
|
||||||
## Configure systemd to start anaconda
|
## Configure systemd to start anaconda
|
||||||
symlink /sbin/init init
|
|
||||||
remove etc/systemd/system/default.target
|
remove etc/systemd/system/default.target
|
||||||
symlink /lib/systemd/system/anaconda.target etc/systemd/system/default.target
|
symlink /lib/systemd/system/anaconda.target etc/systemd/system/default.target
|
||||||
append bin/login "#!/bin/bash"
|
append bin/login "#!/bin/bash"
|
||||||
append bin/login "exec -l /bin/bash"
|
append bin/login "exec -l /bin/bash"
|
||||||
%else:
|
%else:
|
||||||
## Set up loader as init
|
## Set up loader as init
|
||||||
|
remove sbin/init
|
||||||
copy usr/${libdir}/anaconda/init sbin/init
|
copy usr/${libdir}/anaconda/init sbin/init
|
||||||
symlink init sbin/halt
|
symlink init sbin/halt
|
||||||
symlink init sbin/poweroff
|
symlink init sbin/poweroff
|
||||||
symlink init sbin/reboot
|
symlink init sbin/reboot
|
||||||
remove sbin/runlevel sbin/shutdown sbin/telinit
|
remove sbin/runlevel sbin/shutdown sbin/telinit
|
||||||
%endif
|
%endif
|
||||||
|
symlink /sbin/init init
|
||||||
install ${configdir}/network etc/sysconfig
|
install ${configdir}/network etc/sysconfig
|
||||||
append etc/resolv.conf ""
|
append etc/resolv.conf ""
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user