Changeset 567 for client/linuxmuster-client/trunk/share/mount.sh
- Timestamp:
- 11/08/09 13:33:13 (3 years ago)
- File:
-
- 1 edited
-
client/linuxmuster-client/trunk/share/mount.sh (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
client/linuxmuster-client/trunk/share/mount.sh
r540 r567 4 4 # schmitt@lmz-bw.de 5 5 # 6 # 11.07.20096 # 08.11.2009 7 7 # 8 8 … … 14 14 OPTIONS="$5" 15 15 16 # no pammount for local users17 grep -q ^${USER}: /etc/passwd && exit 018 19 16 # check if params are all set 20 17 [ -z "$SERVER" ] && exit 1 … … 24 21 [ -z "$OPTIONS" ] && exit 1 25 22 26 # source profile23 # source various settings and functions 27 24 . /usr/share/linuxmuster-client/profile || exit 1 25 . /etc/linuxmuster-client/config || exit 1 26 . /usr/share/linuxmuster-client/config || exit 1 27 . /usr/share/linuxmuster-client/helperfunctions.sh || exit 1 28 29 # fetch user's homedir 30 get_userhome 31 [[ -z "$HOME" || "$HOME" = "/dev/null" ]] && exit 1 32 33 # only for template user 34 [ "$TEMPLATE_USER" = "$USER" -a "$HOME" = "$MNTPT" ] && . /usr/share/linuxmuster-client/copy-template.sh 35 36 # no pammount for local users 37 grep -q ^${USER}: /etc/passwd && exit 0 28 38 29 39 # check if important variables are set … … 31 41 [ -z "$DESKTOP" ] && exit 1 32 42 [ -z "$USERDIRS" ] && exit 1 33 34 # fetch user's homedir35 get_userhome36 [[ -z "$HOME" || "$HOME" = "/dev/null" ]] && exit 137 43 38 44 # mount the given share … … 44 50 # if userhome not mounted do exit 45 51 cat /proc/mounts | grep -qw $HOME || exit 1 46 47 # add user to mandatory groups48 for i in $MANDATORY_GROUPS; do49 if grep -q $i /etc/group; then50 grep $i /etc/group | grep -q $USER || adduser $USER $i51 fi52 done53 52 54 53 # move user's dirs temporarily to /tmp … … 63 62 done 64 63 64 # copy template user profile 65 . /usr/share/linuxmuster-client/copy-template.sh 66
Note: See TracChangeset
for help on using the changeset viewer.
