Compare commits

..

1 commit

Author SHA1 Message Date
4ff71eb544
silly uki image with the systemd-ukify tooling 2025-02-19 14:02:41 +01:00
2 changed files with 34 additions and 1 deletions

View file

@ -116,6 +116,39 @@
cp ${pkgs.kmod.lib}/lib/* ./usr/lib
cp ${pkgs.libbpf.out}/lib/libbpf* ./usr/lib
# FIXME: remove this
cat <<EOF > usr/lib/systemd/system/demo.service
[Unit]
Description=Debug Shell (/bin/sulogin)
Conflicts=shutdown.target
Before=shutdown.target
[Service]
Environment=HOME=/root
WorkingDirectory=/root
ExecStart=/bin/sulogin
Type=idle
StandardInput=tty-force
StandardOutput=inherit
StandardError=inherit
KillMode=process
IgnoreSIGPIPE=no
SendSIGHUP=yes
Restart=always
[Install]
WantedBy=basic.target
EOF
mkdir usr/lib/systemd/system/basic.target.wants
ln -sf ../demo.service usr/lib/systemd/system/basic.target.wants/demo.service
# set default target
ln -sf basic.target usr/lib/systemd/system/default.target
# remove first boot
rm -f usr/lib/systemd/system/sysinit.target.wants/systemd-firstboot.service
# remove vconsole setup
rm -f usr/lib/udev/rules.d/90-vconsole.rules
# install busybox
cp ${pkgs.busybox.out}/bin/busybox usr/bin/
usr/bin/busybox --list | xargs -I {} ln -sf busybox usr/bin/{}

View file

@ -292,7 +292,7 @@ stdenv.mkDerivation (finalAttrs: {
(lib.mesonEnable "man" false)
(lib.mesonBool "analyze" true)
(lib.mesonBool "logind" false)
(lib.mesonBool "logind" true)
(lib.mesonBool "localed" false)
(lib.mesonBool "hostnamed" true)
(lib.mesonBool "machined" true)