Add run.sh quickstart script
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
#!/usr/bin/env bash
|
||||
# WatchStack-Schnellstart
|
||||
# Legt venv an (falls fehlt), installiert deps, startet uvicorn.
|
||||
set -e
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
if [ ! -d ".venv" ]; then
|
||||
echo "→ Erzeuge venv …"
|
||||
python3 -m venv .venv
|
||||
fi
|
||||
|
||||
# shellcheck disable=SC1091
|
||||
source .venv/bin/activate
|
||||
|
||||
echo "→ Installiere/aktualisiere Abhängigkeiten …"
|
||||
pip install -q --upgrade pip
|
||||
pip install -q -r requirements.txt
|
||||
|
||||
HOST="${HOST:-127.0.0.1}"
|
||||
PORT="${PORT:-8000}"
|
||||
echo "→ Starte WatchStack auf http://${HOST}:${PORT}"
|
||||
exec uvicorn app.main:app --reload --host "${HOST}" --port "${PORT}"
|
||||
Reference in New Issue
Block a user