summaryrefslogtreecommitdiff
path: root/pcr/opensysusers/sysgid.patch
blob: 502217f5b4a1c08da88ac8d77317f6524cb3370a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
From 3f451ccfe5e5943d0ebc98f5f0d095a6c0ee11b4 Mon Sep 17 00:00:00 2001
From: udeved <artoo@cromnix.org>
Date: Sun, 7 Jan 2018 11:08:10 +0100
Subject: [PATCH] sysusers: use a system gid in add_group() if id='-'  to get a
 gid<1000

---
 sysusers | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sysusers b/sysusers
index 80442d3..d71fb61 100755
--- a/sysusers
+++ b/sysusers
@@ -17,7 +17,7 @@ add_group() {
 	getent group "${name}" >/dev/null
 	if [ "$?" -ne 0 ]; then
 		if [ "${id}" == '-' ]; then
-			groupadd "${name}"
+			groupadd -r "${name}"
 		else
 			if ! grep -qiw "${id}" /etc/group; then
 				groupadd -g "${id}" "${name}"