Complete setup and deployment guide for NutriSync.
Follow these guides in order:
- Prerequisites - Required software and accounts
- Database Setup - Supabase configuration and migrations
- API Configuration - Google Gemini AI and USDA API
- Running Locally - Start the application
- Google OAuth - Optional: "Sign in with Google"
- Testing - Run and write tests
- Deployment - Production deployment
- Troubleshooting - Common issues and solutions
Database schema is managed through sequential migration files in backend/migrations/.
See backend/migrations/README.md for details.
- Main README - Project overview
- Backend README - Backend architecture
- Frontend README - Frontend architecture
- CI/CD Workflow - GitHub Actions configuration
Backend (Supabase Edge Function secrets - SUPABASE_URL/SUPABASE_SERVICE_ROLE_KEY are auto-injected):
supabase secrets set GOOGLE_API_KEY=your_gemini_api_key
supabase secrets set USDA_API_KEY=your_usda_keyFrontend (frontend/.env.local):
VITE_SUPABASE_URL=https://[project-ref].supabase.co
VITE_SUPABASE_ANON_KEY=your_anon_key
VITE_API_URL=http://localhost:54321/functions/v1Backend:
supabase functions serve --env-file supabase/.env # Local dev server
supabase functions deploy # Deploy all functions
supabase functions logs <name> # View logsFrontend:
cd frontend
npm install # Install dependencies
npm run dev # Start development server
npm test # Run tests- Check troubleshooting sections in each guide
- Review error messages in browser console and terminal
- Verify environment variables are set correctly
- Ensure all migrations completed successfully