Files
nexus/tools/pi_control/ttyd/entrypoint.sh
2026-03-05 21:59:23 +01:00

18 lines
345 B
Bash

#!/usr/bin/env sh
set -eu
APP_ENV="${APP_ENV:-staging}"
if [ "$APP_ENV" = "live" ]; then
SCRIPT="/app/live/tools/pi_control/terminal_entry.sh"
else
SCRIPT="/app/staging/tools/pi_control/terminal_entry.sh"
fi
if [ ! -f "$SCRIPT" ]; then
echo "terminal_entry.sh not found at $SCRIPT"
exit 1
fi
exec ttyd --writable --url-arg "$SCRIPT"