15 lines
498 B
Bash
15 lines
498 B
Bash
#!/bin/sh
|
|
set -e
|
|
|
|
# Berechtigungen für Volumes setzen (als root)
|
|
chown -R ${PUID:-1000}:${PGID:-1000} /app/data /tmp/sc-config 2>/dev/null || true
|
|
chmod 700 /tmp/sc-config 2>/dev/null || true
|
|
|
|
# Wenn der erste Parameter "python" ist oder das Skript selbst → Python starten
|
|
if [ "$1" = "python" ] || [ "$1" = "/app/scalable_sync.py" ]; then
|
|
shift
|
|
exec gosu appuser python /app/scalable_sync.py "$@"
|
|
fi
|
|
|
|
# Sonst: Befehl direkt als appuser ausführen (z. B. sc login)
|
|
exec gosu appuser "$@" |