Skip to content

Added Option for using systemd-nspawn instead of chroot for hooks

Thore Sommer requested to merge TS/live-build:systemd-nspawn-container into master

This merge request is to upstream changes proposed in #965953.

I work on the same project as Ronny and we needed to integrate flatpak support.
Unfortunately installing flatpaks doesn't work in simple chroots. This patch adds the option to add .container hooks witch are using systemd-nspawn instead of chroot. We build many live systems including flatpaks with the original patch and everything works as expected.

To the original patch I've added systemd-container as recommended dependency and added a check if systemd-cotnainer is installed before a container hook is executed.

If this change gets merged, I'll update the live-manual section for hooks to document this option.

An example of a container hook can be found here: https://github.com/imedias/lernstickAdvanced/blob/debian10/config/hooks/live/enable-flathub.container

Merge request reports

Loading