Skip to contentSkip to conversation

adduser: always add -M option for useradd

PATCH New [email protected] 1 participant 1 message Oct 19, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 adduser: always add -M option for useradd

From: Jackie Huang <[email protected]>

The useradd (from package passwd) in debian based system
sets -M (--no-create-home) by default, but the one we are
using (from package shadow) sets -m (--create-home) by
default, the previous patch added -M option conditionally,
which worked but we see a confused message:
"The home directory /home/newuser' already exists. Not copying from /etc/skel'"

So change it to always add the -M option for useradd and let adduser handle the home creation with its logic.

---
 meta-perl/recipes-perl/adduser/adduser_3.115.bb    |  2 +-
 ...atch => adduser-add-M-option-for-useradd.patch} | 48 ++++++++--------------
 2 files changed, 19 insertions(+), 31 deletions(-)
 rename meta-perl/recipes-perl/adduser/files/{adduser-add-M-option-for-useradd-when-no-create-home.patch => adduser-add-M-option-for-useradd.patch} (38%)
meta-perl/recipes-perl/adduser/adduser_3.115.bb +1 -1
index 312bad8..81068d6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://debian/copyright;md5=caed49ab166f22ef31bf1127f558d0ef"
 
 SRC_URI = "http://ftp.de.debian.org/debian/pool/main/a/${BPN}/${BPN}_${PV}.tar.xz \
-           file://adduser-add-M-option-for-useradd-when-no-create-home.patch \
+           file://adduser-add-M-option-for-useradd.patch \
 "
 
 SRC_URI[md5sum] = "6bb6d93922d281f1b56393a53f8ce5fd"
meta-perl/recipes-perl/adduser/files/adduser-add-M-option-for-useradd.patch renamed from meta-perl/recipes-perl/adduser/files/adduser-add-M-option-for-useradd-when-no-create-home.patch +18 -30

75 lines not on this page · raw message

Signature · 1 line
2.8.3