SpaceBridgeX / scripts /run-api.sh
sarransh's picture
Upload folder using huggingface_hub
528c6f5 verified
Raw History Blame Contribute Delete
325 Bytes
#!/usr/bin/env bash
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
cd "$ROOT"
PORT="${PORT:-8765}"
if [[ ! -d .venv ]]; then
python3 -m venv .venv
.venv/bin/pip install -r backend/requirements.txt
fi
exec .venv/bin/uvicorn main:app --app-dir "$ROOT/backend" --host 127.0.0.1 --port "$PORT" --reload