Building a SlackBuild in an overlay-fs/chroot
by drgibbon from LinuxQuestions.org on (#51KAN)
Lately I've been wanting to test SlackBuilds in an isolated environment (without a full VM, container, etc), so I made a script to do that (sbuild). It builds SlackBuilds in an overlay-fs with chroot (I might try out bwrap at some stage too), and should support system configurations with separate partitions (like /home, or /usr/local).
I've run it through a bit of testing, but I'd be grateful if others who are interested could take a look. I've tried to make it safe and it works so far for me, but no guarantees. Ideally I'd like it not to run as root at all, or at least drop privileges quickly, but at the moment it's root only.
Just to note, the idea of this is not for regular use installing/managing packages-it's for quickly testing a SlackBuild and seeing what it does without affecting the main system.


I've run it through a bit of testing, but I'd be grateful if others who are interested could take a look. I've tried to make it safe and it works so far for me, but no guarantees. Ideally I'd like it not to run as root at all, or at least drop privileges quickly, but at the moment it's root only.
Just to note, the idea of this is not for regular use installing/managing packages-it's for quickly testing a SlackBuild and seeing what it does without affecting the main system.