summaryrefslogtreecommitdiff
path: root/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb
diff options
context:
space:
mode:
Diffstat (limited to 'meta-skeleton/recipes-skeleton/useradd/useradd-example.bb')
-rw-r--r--meta-skeleton/recipes-skeleton/useradd/useradd-example.bb8
1 files changed, 5 insertions, 3 deletions
diff --git a/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb b/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb
index 53d2340af5..7c5b9d0503 100644
--- a/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb
+++ b/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb
@@ -3,8 +3,7 @@ DESCRIPTION = "This recipe serves as an example for using features from useradd.
SECTION = "examples"
PR = "r1"
LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \
- file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
SRC_URI = "file://file1 \
file://file2 \
@@ -15,6 +14,8 @@ S = "${WORKDIR}"
PACKAGES =+ "${PN}-user3"
+EXCLUDE_FROM_WORLD = "1"
+
inherit useradd
# You must set USERADD_PACKAGES when you inherit useradd. This
@@ -32,7 +33,8 @@ USERADD_PACKAGES = "${PN} ${PN}-user3"
USERADD_PARAM_${PN} = "-u 1200 -d /home/user1 -r -s /bin/bash user1; -u 1201 -d /home/user2 -r -s /bin/bash user2"
# user3 will be managed in the useradd-example-user3 pacakge:
-USERADD_PARAM_${PN}-user3 = "-u 1202 -d /home/user3 -r -s /bin/bash user3"
+# As an example, we use the -P option to set clear text password for user3
+USERADD_PARAM_${PN}-user3 = "-u 1202 -d /home/user3 -r -s /bin/bash -P 'user3' user3"
# GROUPADD_PARAM works the same way, which you set to the options
# you'd normally pass to the groupadd command. This will create