aboutsummaryrefslogtreecommitdiffstats
path: root/community/polkit/polkit-common.pre-install
diff options
context:
space:
mode:
authorBart Ribbers <bribbers@disroot.org>2021-11-19 23:02:54 +0100
committerBart Ribbers <bribbers@disroot.org>2021-11-20 12:11:37 +0100
commitff54831613633cfc8b319ecc1b41c81cbb19d38c (patch)
treeb6d5926f4f3d05562328c6b48ffcabff7daf9c33 /community/polkit/polkit-common.pre-install
parent1482116edf87c2abb40119dc8e84794fb8a3f09b (diff)
downloadaports-ff54831613633cfc8b319ecc1b41c81cbb19d38c.tar.gz
aports-ff54831613633cfc8b319ecc1b41c81cbb19d38c.tar.bz2
aports-ff54831613633cfc8b319ecc1b41c81cbb19d38c.tar.xz
community/polkit: make sure we create the polkitd user before installing -common
Otherwise the default polkit rules get installed with the wrong uid and gid, causing problems where polkit asks for the root user password instead of your own user The regular polkit and polkit-elogind will pull in polkit-common anyway, so no need to create the user there too
Diffstat (limited to 'community/polkit/polkit-common.pre-install')
-rw-r--r--community/polkit/polkit-common.pre-install6
1 files changed, 6 insertions, 0 deletions
diff --git a/community/polkit/polkit-common.pre-install b/community/polkit/polkit-common.pre-install
new file mode 100644
index 0000000000..7c4e3eff88
--- /dev/null
+++ b/community/polkit/polkit-common.pre-install
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+addgroup -S polkitd 2>/dev/null
+adduser -S -D -H -h /var/empty -s /sbin/nologin -G polkitd -g polkitd polkitd 2>/dev/null
+
+exit 0