diff --git a/mkuser b/mkuser index 8aff7ad..acc74f4 100755 --- a/mkuser +++ b/mkuser @@ -1,6 +1,10 @@ #!/bin/bash -# This tool generates the users and/or appends the given SSH kjey to the authorized file +# echo $@ >> /etc/ttyserver/mkuser.log +# exit 0 + +#whoami >> /etc/ttyserver/mkuser.log +#exit 0 # $1 = username # $2 = tempfile @@ -23,7 +27,8 @@ if [[ "$1" =~ ^[a-zA-Z0-9][a-zA-Z0-9-]+$ ]]; then # User Exists echo "\"$1\" Exists" >> $LOGFILE else - useradd -G webadd -m -b /htusers -s /usr/bin/bash "$1" + useradd -G webadd -m -b /htusers -s /usr/bin/bash --gid 1004 "$1" + ln -s "/htusers/$1/public_gemini /var/gemini/$1" echo "Added \"$1\" to the system" >> $LOGFILE fi # Ensure SSH filder exists