mirror of
https://github.com/teableio/teable.git
synced 2026-02-19 17:19:50 +08:00
14 lines
336 B
Bash
Executable File
14 lines
336 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -Eeo pipefail
|
|
|
|
if [ "$(id -u)" = '0' ]; then
|
|
# Set the correct permission for local cache
|
|
find /app/.assets \! -user nodejs -exec chown nodejs '{}' +
|
|
find /app/.temporary \! -user nodejs -exec chown nodejs '{}' +
|
|
|
|
# then restart script as nodejs user
|
|
exec gosu nodejs "$BASH_SOURCE" "$@"
|
|
fi
|
|
|
|
exec "$@"
|