diff --git a/bin/vhost-deploy.sh b/bin/vhost-deploy.sh index cd3671e..9fa5d86 100755 --- a/bin/vhost-deploy.sh +++ b/bin/vhost-deploy.sh @@ -89,7 +89,10 @@ if ! grep -q "^$username:" /etc/passwd; then fi # if jail option is set then jail user if [[ -n $jail ]]; then - /usr/local/bin/vhost-user-jail.sh -u $username > /dev/null 2>&1 + # job is run in the background as it can take about 1 minute to complete + /usr/local/bin/vhost-user-jail.sh -u $username >/dev/null 2>/dev/null & + # pause to give above script time to create jail home dir which is used by vhost-add.sh below + sleep 1 fi fi