14 lines
280 B
Bash
14 lines
280 B
Bash
#!/bin/sh
|
|
set -eu
|
|
|
|
ROLE="${APP_ROLE:-gateway}"
|
|
|
|
case "$ROLE" in
|
|
gateway|worker|cron)
|
|
exec uvicorn "app.entrypoints.${ROLE}:app" --host 0.0.0.0 --port 8000
|
|
;;
|
|
*)
|
|
echo "entrypoint: unknown APP_ROLE='$ROLE' (expected gateway|worker|cron)" >&2
|
|
exit 64
|
|
;;
|
|
esac
|