Deployments

Environments

EnvironmentTriggerCrons Active
PreviewPR-based / dev branchNo
Productionmain branch or manual promoteYes

Note: Vercel crons only fire on the production deployment. See APP-CONTROL.md for current deployment status.

Platform

ComponentPlatformDescription
Web appVercelapp.eko.day — authenticated Next.js app
Admin appVerceladmin.eko.day — admin dashboard
Public siteVerceleko.day — marketing site
WorkersBun (standalone)5 queue consumer processes
DatabaseSupabasePostgreSQL with RLS
QueuesUpstash Redis12 queue types, REST API
Object storageCloudflare R2Images and media assets

Deploy Commands

bun run deploy:web      # Deploy web app to Vercel production
bun run deploy:admin    # Deploy admin app to Vercel production
bun run deploy:public   # Deploy public site to Vercel production

These run vercel --prod with the appropriate project scope.

Flow

  1. Push to branch → CI checks (bun run ci)
  2. Preview deployment on Vercel (automatic)
  3. Merge to main → production deploy
  4. Crons activate on production

Workers

Workers are Bun-based queue consumers that run as standalone processes:

WorkerQueuesPurpose
worker-ingestINGEST_NEWS, CLUSTER_STORIES, RESOLVE_IMAGE, RESOLVE_CHALLENGE_IMAGENews ingestion and image resolution
worker-factsEXTRACT_FACTS, IMPORT_FACTS, GENERATE_EVERGREEN, EXPLODE_CATEGORY_ENTRY, FIND_SUPER_FACTS, GENERATE_CHALLENGE_CONTENTFact extraction and challenge generation
worker-validateVALIDATE_FACT4-phase fact verification
worker-reel-render(R2 triggers)Video rendering
worker-smsSEND_SMSSMS notifications

Each worker exposes /health on port 8080 and implements graceful shutdown.

Cron Routes

13 cron routes exist in apps/web/app/api/cron/. Of these, 5 are scheduled in vercel.json and fire automatically on production. The remaining 8 are unscheduled (need manual trigger or external orchestration).

See Cron Actions for the full listing and APP-CONTROL.md for operational details.

Rollbacks

  • Revert commit and push to main
  • Or use vercel rollback to revert to a previous deployment

Secrets

  • Managed via Vercel environment variables (dashboard or vercel env CLI)
  • Never commit secrets — all .env*.local files are in .gitignore
  • See .env.example for the full variable reference