Skip to content

Issue 12: Deploy frontend (Vercel) + backend (Railway) #12

@SriMed

Description

@SriMed

Description

Deploy both services to public URLs for sharing and demo.

Implementation details

  • Frontend: connect GitHub repo to Vercel, set NEXT_PUBLIC_API_URL to Railway backend URL
  • Backend: Railway with Procfile: poetry run python scripts/bootstrap_data.py && poetry run uvicorn main:app --host 0.0.0.0 --port $PORT
  • Add a railway.toml or set the Railway start command to use poetry run — Railway auto-detects pyproject.toml and runs poetry install on deploy
  • Set ANTHROPIC_API_KEY as Railway secret env var (never commit it)
  • Update CORS to allow Vercel production URL
  • Add GET /health endpoint returning {"status": "ok"}
  • ChromaDB must be bootstrapped on Railway: add python scripts/bootstrap_data.py && uvicorn main:app --host 0.0.0.0 --port $PORT to Procfile or a Railway build hook
  • Update README with live demo URL

Acceptance criteria

  • Frontend accessible at public Vercel URL
  • Backend accessible at public Railway URL
  • 'Load Example' and 'Analyze' work end-to-end in production
  • /health returns 200
  • ANTHROPIC_API_KEY is a secret, not in repo
  • ChromaDB populated on Railway deploy
  • README updated with live demo URL

TDD

tests/test_health.py:

  1. GET /health returns 200
  2. GET /health returns {"status": "ok"}

Metadata

Metadata

Assignees

No one assigned

    Labels

    devopsDeployment, infra

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions