From 8c5b00e8970bdf70c98c4a5b0456147a2d1f1ac8 Mon Sep 17 00:00:00 2001 From: Luca Di Maio Date: Sat, 1 Jan 2022 16:03:19 +0100 Subject: [PATCH] init: use different check for user existence (#85) --- distrobox-init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/distrobox-init b/distrobox-init index 73252ee912..d6a5fa57a5 100755 --- a/distrobox-init +++ b/distrobox-init @@ -363,7 +363,7 @@ if ! grep -q "${container_user_name}" /etc/group; then groupadd --force --gid "${container_user_gid}" "${container_user_name}" fi # Let's add our user to the container if the user already exists, just go ahead. -if ! id "${container_user_name}"; then +if ! grep -q "${container_user_name}" /etc/passwd; then if ! useradd \ --home-dir "${container_user_home}" \ --no-create-home \