Skip to main content

Enviroment Variables

Local Development

Create a .env.local file with required variables:

OPENAI_API_KEY=your_key_here
NEXT_PUBLIC_SUPABASE_URL=your_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_key

Production Deployment

Environment variables are configured via:

  1. GitHub Secrets/Variables (.github/workflows/cd.yml):

    • OPENAI_API_KEY → GitHub Secret
    • NEXT_PUBLIC_SUPABASE_URL → GitHub Variable
    • NEXT_PUBLIC_SUPABASE_ANON_KEY → GitHub Variable
  2. Docker Build Args (Dockerfile):

    • Passed during build: --build-arg OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }}
    • Set as ENV in both builder and runner stages
    • Available at build time and runtime