mirror of
https://github.com/nginx/nginx.git
synced 2024-11-25 18:30:26 -06:00
fix --group= vs --user=
This commit is contained in:
parent
5fd6d349c8
commit
80eec93a5f
@ -4,24 +4,25 @@
|
||||
|
||||
NGX_USER=${NGX_USER:-nobody}
|
||||
|
||||
if [ -z "$NGX_GROUP" -a $NGX_USER = nobody ] ; then
|
||||
if grep nobody /etc/group 2>&1 >/dev/null; then
|
||||
echo "checking for nobody group ... found"
|
||||
NGX_GROUP=nobody
|
||||
else
|
||||
echo "checking for nobody group ... not found"
|
||||
|
||||
if grep nogroup /etc/group 2>&1 >/dev/null; then
|
||||
echo "checking for nogroup group ... found"
|
||||
NGX_GROUP=nogroup
|
||||
else
|
||||
echo "checking for nogroup group ... not found"
|
||||
if [ -z "$NGX_GROUP" ]; then
|
||||
if [ $NGX_USER = nobody ]; then
|
||||
if grep nobody /etc/group 2>&1 >/dev/null; then
|
||||
echo "checking for nobody group ... found"
|
||||
NGX_GROUP=nobody
|
||||
fi
|
||||
fi
|
||||
else
|
||||
echo "checking for nobody group ... not found"
|
||||
|
||||
else
|
||||
NGX_GROUP=$NGX_USER
|
||||
if grep nogroup /etc/group 2>&1 >/dev/null; then
|
||||
echo "checking for nogroup group ... found"
|
||||
NGX_GROUP=nogroup
|
||||
else
|
||||
echo "checking for nogroup group ... not found"
|
||||
NGX_GROUP=nobody
|
||||
fi
|
||||
fi
|
||||
else
|
||||
NGX_GROUP=$NGX_USER
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user