Skip to content

Commit

Permalink
Fix reposilite not starting using docker
Browse files Browse the repository at this point in the history
  • Loading branch information
SageSphinx63920 authored Sep 18, 2023
1 parent 7a5a21c commit 10cb3ec
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,15 @@ if [ "$UID" -ne "0" ]; then
$REPOSILITE_ARGS
else
GROUP_ID="${PGID:-999}"
grep "^reposilite" /etc/group > /dev/null
if [ $? -ne 0 ]
if ! grep -q "^reposilite" /etc/group;
then
addgroup --gid "$GROUP_ID" reposilite
addgroup --gid "$GROUP_ID" reposilite;
fi

USER_ID="${PUID:-999}"
grep "^reposilite" /etc/passwd > /dev/null
if [ $? -ne 0 ]
if ! grep "^reposilite" /etc/passwd;
then
adduser --system -uid "$USER_ID" --ingroup reposilite --shell /bin/sh reposilite
adduser --system -uid "$USER_ID" --ingroup reposilite --shell /bin/sh reposilite;
fi

chown -R reposilite:reposilite /app
Expand Down

0 comments on commit 10cb3ec

Please sign in to comment.