Skip to main content

Operations Runbooks

Migrations:

npx wrangler d1 migrations apply chyperai_db --remote
npx wrangler d1 execute chyperai_db --remote --command "SELECT * FROM tenants;"

Seed data:

npx wrangler d1 execute chyperai_db --remote --file db/migrations/0003_seed.sql

Rollback Pages Functions:

  1. Open Pages project in Cloudflare dashboard
  2. Find previous successful deployment
  3. Click Rollback

Rotate secrets:

npx wrangler pages secret delete GITHUB_CLIENT_SECRET
npx wrangler pages secret put GITHUB_CLIENT_SECRET

Incident checklist:

  • Verify /api/hello health.
  • Check Durable Object errors (Worker logs) and D1 availability.
  • Roll forward or back based on deployment status.
  • Communicate status page updates and ETAs.