update to create a user if necessary

This commit is contained in:
ducoterra
2018-09-16 21:01:07 -04:00
parent ccedffd459
commit 3d2c761aa4
Regular → Executable
+4
View File
@@ -186,6 +186,10 @@ fi
tput setaf 2
echo -e "Starting Django project"
tput setaf 0
echo id -u $user
if [ $? = 0 ]; then
adduser $user
fi
if [ ! -d "/home/$user" ] ; then
mkdir /home/$user
chown -R $user:$user /home/$user