summaryrefslogtreecommitdiff
path: root/debian/sane-utils.postinst
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff.email>2022-02-01 15:22:41 +0100
committerJörg Frings-Fürst <debian@jff.email>2022-02-01 15:22:41 +0100
commit97e55bdc5cdf59304af739e65f416320bcbcf599 (patch)
tree32fde9596a10a05f6febd21442c4d24c3328baf9 /debian/sane-utils.postinst
parent0169fc10b4dc6f2872d0e834c4f1ec942f902b3f (diff)
Add home dir for user/group saned
Diffstat (limited to 'debian/sane-utils.postinst')
-rw-r--r--debian/sane-utils.postinst7
1 files changed, 6 insertions, 1 deletions
diff --git a/debian/sane-utils.postinst b/debian/sane-utils.postinst
index 2d47e78..cde28cf 100644
--- a/debian/sane-utils.postinst
+++ b/debian/sane-utils.postinst
@@ -43,7 +43,7 @@ if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
# Create saned user/group if they do not exist
if ! getent passwd | grep -q "^saned:"; then
echo "Adding saned group and user..."
- adduser --home /var/lib/saned --quiet --system --no-create-home --group saned || true
+ adduser --home /var/lib/saned --quiet --system --group saned || true
fi
# Move home from /home/saned to /var/lib/saned (since 1.0.24-6)
@@ -61,6 +61,11 @@ if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
usermod -d /var/lib/saned saned
fi
fi
+
+ if [ ! -d /var/lib/saned saned ] ; then
+ usermod -d /var/lib/saned saned
+ fi
+
if [ "$SANED_IN_SCANNER" = "true" ]; then
adduser --quiet saned scanner
else