alphax/docker/entrypoint.sh
2026-05-16 23:54:43 +08:00

28 lines
434 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
cd /app
mkdir -p /app/data /app/logs
case "${1:-web}" in
web)
exec python -m uvicorn app.web.web_server:app --host 0.0.0.0 --port "${PORT:-8190}"
;;
scheduler)
exec python /app/docker/scheduler.py
;;
price-streamer)
exec python -m app.cli price-streamer
;;
once)
shift
exec python "$@"
;;
shell)
exec bash
;;
*)
exec "$@"
;;
esac