Execute getent in chroot, not on ISO

This commit is contained in:
maride 2017-09-02 17:16:26 +02:00
parent edda8ff56f
commit 5c6d1322e0

View File

@ -16,7 +16,7 @@ else
arch-chroot /mnt passwd $name
# If group "sudo" exists (=> sudo.flavour was installed), ask if the user should be added
if [ $(getent group sudo) ]; then
if [ $(arch-chroot /mnt getent group sudo) ]; then
echo -n "~> Do you want to add $name to sudoers? (Y/n) "
read answer
if [ "$answer" == "y" ] || [ "$answer" == "Y" ]; then