added db setup to deployment file
Some checks failed
Deploy / lint (push) Successful in 4s
Deploy / test (push) Failing after 2s
Deploy / deploy (push) Has been skipped

This commit is contained in:
2026-03-03 19:16:24 +01:00
parent 6a0bd8d099
commit af33f9724c

View File

@@ -11,6 +11,13 @@ name: Deploy
on:
push:
branches: [main]
workflow_dispatch:
inputs:
run_setup_db:
description: "Run deploy/setup_db.sh to configure DB and run migrations"
required: false
type: boolean
default: false
jobs:
lint:
@@ -76,7 +83,12 @@ jobs:
git pull origin main
source .venv/bin/activate
pip install -e .
alembic upgrade head
if [ "${{ inputs.run_setup_db }}" = "true" ] || [ "${{ github.event.inputs.run_setup_db }}" = "true" ]; then
chmod +x deploy/setup_db.sh
./deploy/setup_db.sh
else
alembic upgrade head
fi
cd frontend
npm ci
npm run build