Skip to content

Commit

Permalink
make chown in entrypoint safe from existing uid/gid
Browse files Browse the repository at this point in the history
  • Loading branch information
lreiher committed Dec 23, 2024
1 parent 4a58cb3 commit 7300360
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docker/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ if [[ $DOCKER_UID && $DOCKER_GID ]]; then
ln -s $WORKSPACE /home/$DOCKER_USER/ws
chown -h $DOCKER_UID:$DOCKER_GID $WORKSPACE /home/$DOCKER_USER/ws /home/$DOCKER_USER/.sudo_as_admin_successful
if [[ -d $WORKSPACE/src ]]; then
chown -R $DOCKER_USER:$DOCKER_USER $WORKSPACE/src
chown -R $DOCKER_UID:$DOCKER_GID $WORKSPACE/src
fi
fi
[[ $(pwd) == "$WORKSPACE" ]] && cd /home/$DOCKER_USER/ws
Expand Down

0 comments on commit 7300360

Please sign in to comment.