summaryrefslogtreecommitdiff
path: root/adduser.local
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2002-03-30 02:54:53 +0000
committerJonas Smedegaard <dr@jones.dk>2002-03-30 02:54:53 +0000
commitee3fbfe619b4f8a43f7370fc048e2d95943c0188 (patch)
tree71d947b7b34603730e4053713b22c0e6b54dd4ec /adduser.local
parentf4de52b09e022466e255a1edf75d6a765334ba40 (diff)
Ask about access to local devices in adduser.local, and exit user-init cleanly if unsupported.
Diffstat (limited to 'adduser.local')
-rwxr-xr-xadduser.local21
1 files changed, 20 insertions, 1 deletions
diff --git a/adduser.local b/adduser.local
index e264351..3bf6141 100755
--- a/adduser.local
+++ b/adduser.local
@@ -3,7 +3,7 @@
# /usr/local/sbin/adduser.local
# Copyright 2001-2002 Jonas Smedegaard <dr@jones.dk>
#
-# $Id: adduser.local,v 1.7 2002-03-14 15:28:41 jonas Exp $
+# $Id: adduser.local,v 1.8 2002-03-30 02:54:53 jonas Exp $
#
# Common adduser additions for Spiff and Xenux networks
#
@@ -90,6 +90,25 @@ if [ -f /etc/local/users.conf ]; then
fi
fi
+#if [ -n "$REALUSERS_GROUPNAME" ]; then
+ cat <<+
+Is this a remote or local user (with need for physical
+access to devices like CD-ROM, soundcard and modem needed)?
+
++
+ echo -n "Grant this user access to local utilities (y/N)?"
+ read localuser
+ case $localuser in
+ y|Y)
+ for group in disk dialout cdrom audio video games; do
+ addgroup $NEWUSERNAME $group
+ done
+ ;;
+ *)
+ ;;
+ esac
+#fi
+
if [ -x /usr/local/sbin/user-init ]; then
/usr/local/sbin/user-init $NEWUSERNAME
fi