Skip to content

Staging Pipelines

Overview

Staging runs on pull requests targeting main (and optionally via workflow_dispatch). A single entry workflow, the Staging Orchestrator, runs first. It detects which packages are affected (Turbo build affected vs origin/main), then calls the appropriate reusable workflows only for those targets. A separate validate-e2e job runs lint and typecheck for the E2E package on every PR that runs the orchestrator.

Orchestrator flow

  1. detect-affected — Checkout, install deps, git fetch origin main, run pnpm exec turbo run build --dry=json --affected (base: origin/main). Map package names to workflow target arrays: nextjs_targets (game-client, backoffice-client), web_docs_targets (web-docs-client), storybook_targets (storybook).
  2. call-nextjs-staging-workflow — If any Next.js app is affected, call staging-w-app-nextjs.yml once per target (matrix: game-client, backoffice-client) with deploy_target: local.
  3. call-web-docs-staging-workflow — If web-docs-client is affected, call staging-w-tool-web-docs-client.yml.
  4. call-storybook-staging-workflow — If storybook is affected, call staging-w-tool-storybook.yml.
  5. validate-e2e — Lint and typecheck @kartuli/e2e (no Playwright run).

Workflow files (staging)

WorkflowPurpose
staging-orchestrator.ymlEntry point; detect affected; call per-app/tool workflows; validate-e2e
staging-w-app-nextjs.ymlNext.js apps: build, optional Vercel preview, E2E, Lighthouse
staging-w-tool-web-docs-client.ymlWeb docs: generate LLM bundle, build, preview, E2E
staging-w-tool-storybook.ymlStorybook: build, preview, E2E smoke

Per-app / per-tool docs

References