diff --git a/bin/vhost-user-get.sh b/bin/vhost-user-get.sh index e51d51f..37f98b0 100755 --- a/bin/vhost-user-get.sh +++ b/bin/vhost-user-get.sh @@ -37,7 +37,7 @@ else usernames=(`ls /home/`) fi -output="username uid jailed passwd" +output="username uid jailed passwd fpmmax" for username in "${usernames[@]}" do @@ -49,7 +49,7 @@ do password=`echo "$password" | openssl aes-256-cbc -d -a -pass pass:$opensslpass -pbkdf2` fi else - password= + password="(unknown)" fi shell=(`grep $username /etc/passwd|awk -F : '{ print $6 }'`) if [[ $shell = "/usr/jails/$username/./home/$username" ]]; then @@ -57,7 +57,13 @@ do else jailed="No" fi - output="$output${NL}$username $userid $jailed $password" + vhost::set-phpVersion + if [[ -f /etc/php/$phpVersion/fpm/pool.d/$username.conf ]]; then + fpmmax=(`grep pm.max_children /etc/php/$phpVersion/fpm/pool.d/$username.conf |awk -F = '{ gsub(/ /,""); print $2 }'`); + else + fpmmax=0 + fi + output="$output${NL}$username $userid $jailed $password $fpmmax" done if [[ $cvs ]]; then