From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 40E05138334 for ; Thu, 30 May 2019 12:51:36 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3D29AE093E; Thu, 30 May 2019 12:50:50 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id D6E3AE0930 for ; Thu, 30 May 2019 12:50:49 +0000 (UTC) Received: from localhost.localdomain (d202-252.icpnet.pl [109.173.202.252]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: mgorny) by smtp.gentoo.org (Postfix) with ESMTPSA id 4306C34533E; Thu, 30 May 2019 12:50:48 +0000 (UTC) From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= To: gentoo-dev@lists.gentoo.org Cc: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Subject: [gentoo-dev] [PATCH 2/9] user.eclass: Prevent automated home creation in useradd Date: Thu, 30 May 2019 14:50:32 +0200 Message-Id: <20190530125039.15591-3-mgorny@gentoo.org> X-Mailer: git-send-email 2.22.0.rc1 In-Reply-To: <20190530125039.15591-1-mgorny@gentoo.org> References: <20190530125039.15591-1-mgorny@gentoo.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Archives-Salt: f70674dc-d7c3-480e-94b4-e0d50368affc X-Archives-Hash: 6cdb8a91c2e28a3c9dfa8f643a28fe6c Pass '-M' to prevent useradd from automatically creating the home directory (depending on system configuration). We create the home directory ourselves anyway, and we have better control over how it's created this way. Signed-off-by: Michał Górny --- eclass/user.eclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eclass/user.eclass b/eclass/user.eclass index a6c6ad82b7a0..6be76666d9f3 100644 --- a/eclass/user.eclass +++ b/eclass/user.eclass @@ -246,7 +246,7 @@ enewuser() { ;; *) - useradd -N -r "${opts[@]}" "${euser}" || die + useradd -M -N -r "${opts[@]}" "${euser}" || die ;; esac -- 2.22.0.rc1