fosslinux / live-bootstrap

Use of a Linux initramfs to fully automate the bootstrapping process
482 stars 32 forks source link

Add small bubblewrap like program as a build step #339

Open MaxHearnden opened 9 months ago

MaxHearnden commented 9 months ago

This allow the user to perform a rootless build without bubblewrap on machines with user namespaces enabled

fosslinux commented 9 months ago

I understand the idea/implementation in principle. Would you mind outlining any particular, specific usecases for this?

MaxHearnden commented 9 months ago

It's to reduce the binary seed required for an unprivileged build to just hex0+kaem-optional and can be used with the following commands

cp sysa/stage0-posix/src/* .
cp sysa/after_wrap.kaem after.kaem

# This stage could be integrated into after_wrap.kaem
echo "CHROOT=True
CHROOT_WRAP=True" >> sysa/bootstrap.cfg

./bootstrap-seeds/POSIX/x86/kaem-optional-seed
oriansj commented 9 months ago

I like it but 2 minor details: 1) the syscalls should added to M2libc such that the code becomes more standard C. 2) the wrap.c program belongs in mescc-tools-extra which live-bootstrap does already use and will allow other bootstrapping projects to leverage your work.

great work

fosslinux commented 8 months ago

If this could be

  1. rebased on master
  2. updated to reflect that wrap.c is in mescc-tools-extra

I think I'm happy to include this in principle.

Googulator commented 7 months ago

436 will bring in wrap.c into live-bootstrap, although currently unused