Merge pull request #9 from thelittlefireman/master

UID=0 or GID=0 will set default user or group respectively to root.
This commit is contained in:
PlusMinus0 2017-10-04 11:40:07 +02:00 committed by GitHub
commit da75fcec18

View file

@ -7,7 +7,7 @@ function stopJD2 {
exit exit
} }
if [ "$GID" ] if [ "$GID" ] && [ "$GID" -ne "0" ]
then then
GROUP=jdownloader GROUP=jdownloader
groupadd -g $GID $GROUP groupadd -g $GID $GROUP
@ -15,7 +15,7 @@ else
GROUP=root GROUP=root
fi fi
if [ "$UID" ] if [ "$UID" ] && [ "$UID" -ne "0" ]
then then
USER=jdownloader USER=jdownloader
useradd -r -N -s /bin/false -u $UID $USER useradd -r -N -s /bin/false -u $UID $USER