mirror of
https://github.com/Monadical-SAS/reflector.git
synced 2025-12-20 12:19:06 +00:00
* Self-hosted gpu api * Refactor self-hosted api * Rename model api tests * Use lifespan instead of startup event * Fix self hosted imports * Add newlines * Add response models * Move gpu dir to the root * Add project description * Refactor lifespan * Update env var names for model api tests * Preload diarizarion service * Refactor uploaded file paths
18 lines
430 B
Bash
18 lines
430 B
Bash
#!/bin/sh
|
|
set -e
|
|
|
|
export PATH="/root/.local/bin:$PATH"
|
|
cd /app
|
|
|
|
# Install Python dependencies at runtime (first run or when FORCE_SYNC=1)
|
|
if [ ! -d "/app/.venv" ] || [ "$FORCE_SYNC" = "1" ]; then
|
|
echo "[startup] Installing Python dependencies with uv..."
|
|
uv sync --compile-bytecode --locked
|
|
else
|
|
echo "[startup] Using existing virtual environment at /app/.venv"
|
|
fi
|
|
|
|
exec uv run uvicorn main:app --host 0.0.0.0 --port 8000
|
|
|
|
|