Subject: bug#71657: Improve support for generating system images with different file systems

From: Richard Sent <[email-masked]>
Date: Wed, 19 Jun 2024 16:18:27 -0400

Hi Guix!

I was surprised to find out that $ guix system image and pals only
support a small subset of the file systems Guix has available.  (ext2-4,
vfat, and fat32)

What's more, even if an alternative file system is supported (it's not)
changing the root filesystem format alongside an operating-system is a
fairly involved process. By default, image constructors seem to ignore
the file-system field of an operating system when generating partitions
and formatting them.

I think the following changes would be ideal:

1. Add more make-*-image functions to gnu/build/image.scm to support
common file systems people would want to use.

2. Capture the root filesystem type from an operating-system record and
use it when generating the root filesystem partition on the image.

It's not always possible to manually partition disks and run guix system
init (cloud providers, efi bootloader installation on sbcs) ahead of
time on an external machine, so I feel there is a valid use case here.

If nothing else, I'd like a warning to be emitted if an
operating-system's file-system structure does not match what $ guix
system image generates.

-- 
Take it easy,
Richard Sent
Making my computer weirder one commit at a time.