diff options
author | Simon Rettberg | 2020-08-03 18:04:59 +0200 |
---|---|---|
committer | Your Name | 2020-08-03 18:04:59 +0200 |
commit | a069ecafe76710cdc758f5c79a7c000bfe3a7e76 (patch) | |
tree | bc8de78515c7b5d0c24ffc3e7e216e5d846082bb /core/rootfs/rootfs-stage31/data/init | |
parent | [rfs-stage31] Fix hostname lookup for newer busybox nslookup (diff) | |
download | mltk-a069ecafe76710cdc758f5c79a7c000bfe3a7e76.tar.gz mltk-a069ecafe76710cdc758f5c79a7c000bfe3a7e76.tar.xz mltk-a069ecafe76710cdc758f5c79a7c000bfe3a7e76.zip |
[systemd-distro] Get this module into working state, switch
Diffstat (limited to 'core/rootfs/rootfs-stage31/data/init')
-rwxr-xr-x | core/rootfs/rootfs-stage31/data/init | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/core/rootfs/rootfs-stage31/data/init b/core/rootfs/rootfs-stage31/data/init index 3f39c66e..00a88667 100755 --- a/core/rootfs/rootfs-stage31/data/init +++ b/core/rootfs/rootfs-stage31/data/init @@ -189,7 +189,10 @@ if [ ! -z "$SLX_DEMO_PASS" ]; then fi # Activate debug shell after switchroot? -[ -n "$DEBUG_SHELL" ] && ln -s "../debug-shell.service" "${FUTURE_ROOT}/usr/lib/systemd/system/sysinit.target.wants/debug-shell.service" +if [ -n "$DEBUG_SHELL" ]; then + mkdir -p "${FUTURE_ROOT}/etc/systemd/system/sysinit.target.wants" + ln -s "../debug-shell.service" "${FUTURE_ROOT}/etc/systemd/system/sysinit.target.wants/debug-shell.service" +fi # Exam mode if [ -n "$SLX_EXAM" ]; then @@ -233,8 +236,11 @@ echo "$bench_result" > "${FUTURE_ROOT}/opt/openslx/.benchmark" unset BOOT_IMAGE initrd KCL ip slxbase slxsrv IPINFO vga ip MAC BOOTIF DEBUG OLDPWD MUTED_OUTPUT GFX unset ip router dns hostname domain search if ntpsrv export HOME=/ -export init="/usr/lib/systemd/systemd" export recovery= export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/openslx/sbin:/opt/openslx/bin" -exec /sbin/switch_root -c /dev/console /mnt /usr/lib/systemd/systemd $SD_CMDLINE +for init in "/lib/systemd/systemd" "/usr/lib/systemd/systemd"; do + [ -x "${FUTURE_ROOT}/${init}" ] || continue + export init + exec /sbin/switch_root -c /dev/console /mnt "$init" $SD_CMDLINE +done |