Deployment

ShockStack supports frontend-focused deployment and full-stack container deployment.

Deployment Targets

  • Frontend runtime deployment
  • Containerized full-stack deployment

Choose based on whether you need only the web app or the complete API/database stack.

Required Environment Variables

VariableScopePurpose
DATABASE_URLAppDatabase connection
BETTER_AUTH_SECRETAppSession/auth signing secret
BETTER_AUTH_URLAppPublic application URL
CLOUDFLARE_API_TOKENCI/CDFrontend deployment credentials
CLOUDFLARE_ACCOUNT_IDCI/CDFrontend deployment account
ConnectionStrings__DefaultConnectionBackendBackend database connection
Cors__Origins__0BackendAllowed frontend origin

Typical Frontend Deploy Flow

  1. Build design tokens
  2. Build frontend artifacts
  3. Publish runtime bundle with deployment CLI/tooling

Typical Full-Stack Deploy Flow

  1. Build and tag backend container image
  2. Push image to container registry
  3. Deploy runtime with environment variables and secrets
  4. Run health checks and rollout verification

CI/CD Behavior

  • CI runs lint, typecheck, test, and build tasks
  • Release automation publishes changelog/tag artifacts
  • Deploy automation can publish frontend and backend independently

Rollout Checklist

  • Validate env vars/secrets are set in target environment
  • Confirm database connectivity before cutover
  • Verify readiness/liveness endpoints after deploy
  • Confirm auth flow works end-to-end in production URL