Update entrypoint.sh

This commit is contained in:
Nikolai Kochetov 2021-07-20 15:02:20 +03:00 committed by GitHub
parent 9abd7e543c
commit 4df50d3490
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -72,6 +72,7 @@ do
if [ "$DO_CHOWN" = "1" ]; then
# ensure proper directories permissions
# but skip it for if directory already has proper premissions, cause recursive chown may be slow
if [ "$(stat -c %u "$dir")" != "$USER" ] || [ "$(stat -c %g "$dir")" != "$GROUP" ]; then
chown -R "$USER:$GROUP" "$dir"
elif ! $gosu test -d "$dir" -a -w "$dir" -a -r "$dir"; then