public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Uladzimir Bely <ubely@ilbers.de>
To: isar-users@googlegroups.com
Subject: [PATCH 2/2] image-account-extension: Move examples to user manual
Date: Tue, 30 Jan 2024 11:15:06 +0100	[thread overview]
Message-ID: <20240130101506.27451-3-ubely@ilbers.de> (raw)
In-Reply-To: <20240130101506.27451-1-ubely@ilbers.de>

Based on discussion in https://github.com/ilbers/isar/issues/103

Signed-off-by: Uladzimir Bely <ubely@ilbers.de>
---
 doc/user_manual.md                           | 22 ++++++++++++++++++++
 meta/classes/image-account-extension.bbclass | 18 ----------------
 2 files changed, 22 insertions(+), 18 deletions(-)

diff --git a/doc/user_manual.md b/doc/user_manual.md
index 27b86869..747b5ffe 100644
--- a/doc/user_manual.md
+++ b/doc/user_manual.md
@@ -700,6 +700,28 @@ The `USERS` and `USER:<username>` variable works similar to the `GROUPS` and `GR
    - `clear-text-password` - The `password` flag of the given user contains a clear-text password and not an encrypted version of it.
    - `force-passwd-change` - Force the user to change to password on first login.
 
+#### Example
+
+```
+GROUPS += "root"
+GROUP_root[gid] = "0"
+GROUP_root[flags] = "system"
+
+USERS += "root"
+USER_root[password] = "$6$rounds=10000$RXeWrnFmkY$DtuS/OmsAS2cCEDo0BF5qQsizIrq6jPgXnwv3PHqREJeKd1sXdHX/ayQtuQWVDHe0KIO0/sVH8dvQm1KthF0d/"
+USER_root[expire] = "180"
+USER_root[inactive] = "30"
+USER_root[uid] = "0"
+USER_root[gid] = "0"
+USER_root[comment] = "The ultimate root user"
+USER_root[home] = "/home/root"
+USER_root[shell] = "/bin/sh"
+USER_root[groups] = "audio video"
+USER_root[flags] = "create-home system force-passwd-change"
+```
+
+Some examples can be also found in `meta-isar/conf/local.conf.sample`.
+
 #### Home directory contents prefilling
 
 To cover all users simply use `/etc/skel`. Files in there will be available in every home directory under correct permissions.
diff --git a/meta/classes/image-account-extension.bbclass b/meta/classes/image-account-extension.bbclass
index 412aa06d..9e67cb91 100644
--- a/meta/classes/image-account-extension.bbclass
+++ b/meta/classes/image-account-extension.bbclass
@@ -6,26 +6,8 @@
 # This class extends the image.bbclass for creating user accounts and groups.
 
 USERS ??= ""
-
-#USERS += "root"
-#USER_root[password] = "" # Encrypted password, or clear-text when [flags] = "clear-text-password"
-#USER_root[expire] = ""
-#USER_root[inactive] = ""
-#USER_root[uid] = ""
-#USER_root[gid] = "" # If first character is a number: gid, otherwise groupname
-#USER_root[comment] = "The ultimate root user"
-#USER_root[home] = "/home/root"
-#USER_root[shell] = "/bin/sh"
-#USER_root[groups] = "audio video"
-#USER_root[flags] = "no-create-home create-home system allow-empty-password clear-text-password force-passwd-change"
-
 GROUPS ??= ""
 
-#GROUPS += "root"
-#GROUP_root[gid] = ""
-#GROUP_root[flags] = "system"
-
-
 def image_create_groups(d: "DataSmart") -> None:
     """Creates the groups defined in the ``GROUPS`` bitbake variable.
 
-- 
2.20.1


  parent reply	other threads:[~2024-01-30 10:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-30 10:15 [PATCH 0/2] Updates in the documentation Uladzimir Bely
2024-01-30 10:15 ` [PATCH 1/2] doc/user_manual.md: Fix/update the contents Uladzimir Bely
2024-01-30 10:15 ` Uladzimir Bely [this message]
2024-02-06  8:09 ` [PATCH 0/2] Updates in the documentation Uladzimir Bely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240130101506.27451-3-ubely@ilbers.de \
    --to=ubely@ilbers.de \
    --cc=isar-users@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox