Subject: [bug#75414] [PATCH 2/2] deploy: Add roll-back action.

From: Evgeny Pisemsky <[email-masked]>
Date: Fri, 24 Jan 2025 18:45:40 +0300

> Hmm I would rather have ‘guix deploy --roll-back’, although that’d be
> different from ‘guix system’, primarily because I don’t see what other
> actions we could have, and in particular how we’d name the default
> action (‘guix deploy deploy’? ‘guix deploy really’? ‘guix deploy
> please’?).

The default action is =system reconfigure= on remote machine(s).

This patch implements =system roll-back= on remote machine(s)

I really miss =system delete-generations= on remote machine(s), which
understands =build-locally?= and does not trigger a lot of downloads
just to update grub, which happens when I run it directly on machine.

So one can see the tendency here - reimplementing system actions for
deploy. Since machine definition includes system definition, how bad
is the idea to just make deploy a feature of specific system actions?
Even in the manual they follow each other in the same system section.

On the other hand, it is clear that all system commands work with a
single operating system, and adding deploy may be conceptually wrong.

But if it is not, I think about an UI analogous to guix container:

#+begin_example
guix system reconfigure --machine servers.scm
guix machine exec servers.scm -- herd restart something
#+end_example

The first command actually works with systems on remote machine(s).
The second one is specific to machine(s), without affecting systems.

To me this is more flexible than one command that does everything. I
can imagine a situation when I just need to run some command on all
machines without reconfiguring them, which is currently impossible.

Of course, this is not an objection to the patch, just a brain dump.