#779578 user-setup: Please install sudo when installing without root password

#779578#5
Date:
2015-03-02 16:02:16 UTC
From:
To:
I installed jessie from the daily netinst image and did not enter a
password for root. The end result was a working system without root
access as sudo was not installed.

The installer should make sure that sudo is installed, when the root
password is left empty.

I was installing on a hard-drive with /etc and /home from a previous
jessie install. The installer should also add the user created during
root-passwordless installation to the group 'sudo', but since my previous
install already had this, I do not know if this is made on fresh
install.

#779578#10
Date:
2015-03-02 17:00:45 UTC
From:
To:
Teemu Ikonen <tpikonen@gmail.com> (2015-03-02):

Err, installing sudo and making the first user a sudoer is what is
supposed to happen in such a case. The existing /etc && /home might
have had some kind of influence on the net results.

Mraw,
KiBi.

#779578#17
Date:
2015-03-02 17:43:44 UTC
From:
To:
Cyril Brulebois <kibi@debian.org> wrote:

Indeed that seems to be the case. Looking at user-setup-apply, line 154
has a conditional which only installs sudo if /etc/sudoers does not
exist in the target. This test obviously fails to do the right thing
when installing with an existing /etc.

If the next line (157) which has the installation commands is a no-op
when sudo is installed (at least it should be), then I think the
conditional could be removed completely.

Best,
Teemu