Fix database migrations for Railway deployment

- Add InviteCode model import to alembic env.py
- Derive DATABASE_URL_SYNC from DATABASE_URL as a property
  so it uses the same Railway-provided connection string

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Michael Chihlas
2026-02-01 00:53:55 -05:00
parent 068c691773
commit 7b0788712d
2 changed files with 5 additions and 9 deletions

View File

@@ -9,7 +9,7 @@ from alembic import context
# Import your models
from app.core.database import Base
from app.models import User, Team, Tree, Session, Attachment
from app.models import User, Team, Tree, Session, Attachment, InviteCode
from app.core.config import settings
# this is the Alembic Config object