aboutsummaryrefslogtreecommitdiff
path: root/nix/rootfs.nix
diff options
context:
space:
mode:
authorArslaan Pathan <[email protected]>2026-06-08 19:59:29 +1200
committerArslaan Pathan <[email protected]>2026-06-08 19:59:29 +1200
commit93f35914637f53007f4fddb4d64069612c7b2b2f (patch)
tree5bb92695711b46eb919852f3a3458bf9ea76a1d2 /nix/rootfs.nix
parent18ee85b9efe6ab31db652e9a9f919603ca5edd4b (diff)
downloadyerbalinux-93f35914637f53007f4fddb4d64069612c7b2b2f.tar.xz
yerbalinux-93f35914637f53007f4fddb4d64069612c7b2b2f.zip
Fix init issue and work on making graphical tty show
Diffstat (limited to 'nix/rootfs.nix')
-rw-r--r--nix/rootfs.nix8
1 files changed, 5 insertions, 3 deletions
diff --git a/nix/rootfs.nix b/nix/rootfs.nix
index fc5d321..d463af7 100644
--- a/nix/rootfs.nix
+++ b/nix/rootfs.nix
@@ -1,15 +1,17 @@
-{ stdenv, fetchgit, busybox, squashfsTools }:
+{ stdenv, fetchgit, busybox, squashfsTools, linuxHeaders }:
stdenv.mkDerivation {
name = "rootfs-yerba";
src = ./.;
buildInputs = [ squashfsTools ];
- nativeBuildInputs = [ squashfsTools ];
+ nativeBuildInputs = [ squashfsTools linuxHeaders ];
buildPhase = ''
mkdir -p rootfs
mkdir -p rootfs/{bin,sbin,etc,proc,sys,dev,home,var,usr,root,mnt,tmp}
cp -a ${busybox}/_install/. rootfs/
- # this says permission denied, cant be bothered to debug, let's just hope we can chroot to /sbin/init in the initramfs and it works?
+ chmod -R u+w rootfs
+ ln -sf bin/busybox rootfs/init
+ ln -sf bin/busybox rootfs/sbin/init
# ln -sf sbin/init rootfs/init
echo "proc /proc proc defaults 0 0" > rootfs/etc/fstab
echo "sysfs /sys sysfs defaults 0 0" >> rootfs/etc/fstab