MSL Wiki
MSL on GitHub

Custom images

Run your own Linux: a folder with a kernel, an initramfs and a disk.

Chapter 2 of 202 min read
On this page 3 sections

Besides MSL's own distros, an instance can run a Linux image you made yourself — any distro, any setup, your dotfiles baked in. A custom image is just a folder with three files, and MSL runs it the way it runs its own.

The quickest way: start from a distro#

In New Instance, open Start a custom image from a distro, pick an installed distro, give the image a name and choose Create Image. MSL copies that distro into Custom Images as your own image. The copy is instant and takes no extra space until it changes, and everything MSL needs is already inside.

Then create an instance from it, install whatever you like, and it stays that way — changes to your image never touch the distro it came from.

From Terminal: msl images new my-image --distro debian, then msl new work --distro custom:my-image.

Making one from scratch#

Choose Open Folder under Custom images in New Instance (or run msl images open). MSL opens Custom Images in Finder, with a README and a guest kit inside. Make a folder — its name is the image's id, in letters, digits, - and _ — and put in:

FileWhat it is
ImageThe kernel: a raw arm64 kernel Image, not a compressed vmlinuz.
initramfsAn initramfs that can mount ext4 on an NVMe disk.
rootfs.imgThe root filesystem: a raw ext4 image with no partition table.
image.jsonOptional: a name, a description, and a kernelCommandLine if yours needs one.

Choose Rescan, and the image appears. If something's wrong — a compressed kernel, a partitioned disk, a missing file — MSL lists the image with exactly what to fix.

Removing one#

Right-click an instance and choose Remove … Image. Its instances go; the folder and its files stay — MSL never deletes anything in Custom Images. Delete the folder yourself when you're done with it.