reorganization
This commit is contained in:
25
startup-dev.sh
Executable file
25
startup-dev.sh
Executable file
@@ -0,0 +1,25 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
echo "Initializing directories..."
|
||||
mkdir -p /app/data/chromadb
|
||||
|
||||
echo "Rebuilding frontend..."
|
||||
cd /app/raggr-frontend
|
||||
yarn build
|
||||
cd /app
|
||||
|
||||
echo "Setting up database..."
|
||||
# Give PostgreSQL a moment to be ready (healthcheck in docker-compose handles this)
|
||||
sleep 3
|
||||
|
||||
if ls migrations/models/0_*.py 1> /dev/null 2>&1; then
|
||||
echo "Running database migrations..."
|
||||
aerich upgrade
|
||||
else
|
||||
echo "No migrations found, initializing database..."
|
||||
aerich init-db
|
||||
fi
|
||||
|
||||
echo "Starting Flask application in debug mode..."
|
||||
python app.py
|
||||
Reference in New Issue
Block a user