Gentoo Archives: gentoo-commits

From: "Ulrich Müller" <ulm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/devmanual:master commit in: ebuild-writing/users-and-groups/
Date: Thu, 23 Jan 2020 19:30:23
Message-Id: 1579807775.56eb6bc591c3daff893e9060faed0c04b4adb7f1.ulm@gentoo
1 commit: 56eb6bc591c3daff893e9060faed0c04b4adb7f1
2 Author: Ulrich Müller <ulm <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jan 23 19:29:35 2020 +0000
4 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org>
5 CommitDate: Thu Jan 23 19:29:35 2020 +0000
6 URL: https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=56eb6bc5
7
8 ebuild-writing/users-and-groups: Use example ebuilds from tree.
9
10 The acct-user/group ebuilds for suricata are rather typical examples,
11 so replace the fictitious user 123 by them.
12
13 This also has ${PN} as single element in ACCT_USER_GROUPS, and it
14 drops the uncommon ACCT_USER_{SHELL,HOME{,_OWNER,_PERMS}} variables
15 from the example.
16
17 Original patch from Michael Orlitzky <mjo <AT> gentoo.org> (who asked me to
18 put my own name on it).
19
20 Closes: https://bugs.gentoo.org/702508
21 Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>
22
23 ebuild-writing/users-and-groups/text.xml | 22 +++++++++-------------
24 1 file changed, 9 insertions(+), 13 deletions(-)
25
26 diff --git a/ebuild-writing/users-and-groups/text.xml b/ebuild-writing/users-and-groups/text.xml
27 index 184f890..294d558 100644
28 --- a/ebuild-writing/users-and-groups/text.xml
29 +++ b/ebuild-writing/users-and-groups/text.xml
30 @@ -42,8 +42,8 @@ and must not be used for new packages.
31
32 <p>
33 Group ebuilds are placed in <c>acct-group</c> category, with the package name
34 -matching the group name. The following can be used as a template for writing
35 -group ebuilds:
36 +matching the group name. The following ebuild for <c>acct-group/suricata</c>
37 +can be used as a template for writing group ebuilds:
38 </p>
39
40 <pre>
41 @@ -54,8 +54,8 @@ EAPI=7
42
43 inherit acct-group
44
45 -DESCRIPTION="Meaningful description of the group"
46 -ACCT_GROUP_ID=123
47 +DESCRIPTION="Group for Suricata IDS"
48 +ACCT_GROUP_ID=477
49 </pre>
50
51 <p>
52 @@ -71,8 +71,8 @@ ACCT_GROUP_ID=123
53
54 <p>
55 User ebuilds are placed in <c>acct-user</c> category, with the package name
56 -matching the user name. The following can be used as a template for writing
57 -user ebuilds:
58 +matching the user name. The following ebuild for <c>acct-user/suricata</c>
59 +can be used as a template for writing user ebuilds:
60 </p>
61
62 <pre>
63 @@ -83,13 +83,9 @@ EAPI=7
64
65 inherit acct-user
66
67 -DESCRIPTION="Meaningful description of the user"
68 -ACCT_USER_ID=123
69 -ACCT_USER_SHELL=/usr/bin/foo
70 -ACCT_USER_HOME=/var/lib/foo
71 -ACCT_USER_HOME_OWNER=foo:bar
72 -ACCT_USER_HOME_PERMS=0775
73 -ACCT_USER_GROUPS=( foo bar baz )
74 +DESCRIPTION="User for Suricata IDS"
75 +ACCT_USER_ID=477
76 +ACCT_USER_GROUPS=( ${PN} )
77
78 acct-user_add_deps
79 </pre>