make sure the new user has a home
This commit is contained in:
parent
e8daa5f7f7
commit
a03739b204
@ -11,7 +11,7 @@ CMDS=($CMDS) # convert to array
|
|||||||
if ! id "$USER" 2&>/dev/null; then
|
if ! id "$USER" 2&>/dev/null; then
|
||||||
echo 'INFO: User not found'
|
echo 'INFO: User not found'
|
||||||
echo 'Creating...'
|
echo 'Creating...'
|
||||||
useradd --shell /usr/bin/bash $USER
|
useradd --create-home --shell /usr/bin/bash $USER
|
||||||
echo "Password for $USER:"
|
echo "Password for $USER:"
|
||||||
passwd $USER
|
passwd $USER
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user