Subject: [bug#74531] [PATCH] system: Add "installer" sub-command.

From: Mathieu Othacehe <[email-masked]>
Date: Tue, 03 Dec 2024 08:57:06 +0100

Hello Janneke,

> Subject: [PATCH] system: Add "installer" sub-command.
>
> * guix/scripts/system/installer.scm: New file.
> * Makefile.am (MODULES)[ENABLE_INSTALLER]: Register it.
> (MODULES_NOT_COMPILED)[!ENABLE_INSTALLER]: Likewise.
> * guix/scripts/system.scm (show-help): Add help for "installer" sub-command.
> (actions): Register "installer".
> (guix-system): Invoke `guix-system-installer' sub-command.
> * doc/guix.texi (Invoking guix system): Document it.
> * gnu/installer.scm (run-installer): Remove "./pre-inst env".

That looks great thanks!

It makes me think that we could go further than that an come-up with a
command that would look like:

--8<---------------cut here---------------start------------->8---
guix system image --installer os-1.scm os-2.scm
--8<---------------cut here---------------end--------------->8---

That would generate a bootable image, that would contain the closure of
all the provided system configurations (os-1.scm, os-2.scm, ...).

That image would run the installer and would directly propose the
installation of the os-1 or the os-2 to the user. Most of the
installations pages could then be skipped, except the host-name and
partitioning pages.

That way, one could generate an image with say, a Hurd based system
configuration and a Linux based system configuration and then, pick in
the installer the system to be installed. As the image contains the
closure of both systems, there would be no network issues.

Mathieu