2026-04-23 23:40:34 -03:00
|
|
|
#!/bin/bash
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
|
|
mkdir -p /app/data/streams
|
|
|
|
|
mkdir -p /app/data/logs
|
2026-04-24 23:08:42 -03:00
|
|
|
mkdir -p /app/data/vnc-tokens
|
2026-04-23 23:40:34 -03:00
|
|
|
|
2026-04-25 15:08:25 -03:00
|
|
|
# Migrate streams.json from old location (/app/data/streams.json → /app/data/streams/streams.json)
|
|
|
|
|
if [ -f /app/data/streams.json ] && [ ! -f /app/data/streams/streams.json ]; then
|
|
|
|
|
mv /app/data/streams.json /app/data/streams/streams.json
|
|
|
|
|
echo "[entrypoint] migrated streams.json to /app/data/streams/streams.json"
|
|
|
|
|
fi
|
2026-04-23 23:40:34 -03:00
|
|
|
|
2026-04-25 15:08:25 -03:00
|
|
|
# Regenerate stream configs from current image templates before supervisord reads them
|
|
|
|
|
node /opt/scripts/reprovision.mjs
|
2026-04-24 23:08:42 -03:00
|
|
|
|
|
|
|
|
exec /usr/bin/supervisord -c /etc/supervisor/supervisord.conf
|