Although it is very easy to create a systemd container with EOS, I decided to offer a prebuilt minimal container that can be imported into your system with a single command.
The container will be installed in the default location which is
If that directory is on a BTRFS filesystem, a subvolume with the machine will be created.
To install quick&fast:
sudo machinectl pull-tar --verify=checksum https://github.com/torvic9/eos-systemd-container/raw/master/eos-container.tar.xz
Optionally, to bind-mount your pacman cache read-only:
sudo cp /var/lib/machines/eos-container/eos-container.nspawn /etc/systemd/nspawn
To boot the container:
sudo machinectl start eos-container
To login into the container:
sudo machinectl login eos-container
sudo systemd-nspawn -bUM eos-container
It comes with a preconfigured user account:
eos1 (same as for root)
To bind-mount other directories from the host, edit
Feedback is welcome!
EDIT: you can also use this container on a different distro as long as it runs systemd. It’s not EndeavourOS specific.