Subject: bug#54666: closed (Re: bug#54666: Installation without non-root user accounts)

From: [email-masked] (GNU bug Tracking System)
Date: Wed, 06 Apr 2022 19:22:01 +0000

Your bug report

#54666: Installation without non-root user accounts

which was filed against the guix package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
54666: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=54666
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#54666: Installation without non-root user accounts
From: Mathieu Othacehe <[email-masked]>
To: Ludovic Courtès <[email-masked]>
Cc: [email-masked]
Date: Wed, 06 Apr 2022 21:20:58 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

Hey!

> Nitpick: you can omit ‘begin’ here.

Fixed it before pushing, thanks for having a look.

Mathieu

Subject: Installation without non-root user accounts
From: Ludovic Courtès <[email-masked]>
To: [email-masked]
Date: Fri, 01 Apr 2022 12:31:34 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

Hello!

Using the installer, it’s possible to create a system config without any
non-root user accounts.  That’s a problem because then users end up
creating their account manually with ‘useradd’, which gets things wrong,
and things go awry.

To reproduce the issue, in the user page of the installer, add an
account for user “root”.  That’s enough to fool this check:

     (when (null? users)
       (run-error-page (G_ "Please create at least one user.")
                       (G_ "No user"))
       (run users))

This “root” account is then ignored:

  (define (users->configuration users)
    ;; …
    `((users (cons*
              ,@(filter-map (lambda (user)
                              ;; Do not emit a 'user-account' form for "root".
                              (and (not (string=? (user-name user) "root"))
                                   (user->sexp user)))
                            users)
              %base-user-accounts))))

… and that’s how you end up with a config without normal user accounts.

To address that, maybe ‘run-user-add-page’ should explicitly reject
“root”?

Ludo’.