1.2 KiB
1.2 KiB
MS-GATE-001 Scratchpad
Objective
Build the API Gatekeeper module for PR auto-merge orchestration using Gitea PR webhooks, Woodpecker CI webhooks, and a pending_merges Prisma model.
Constraints
- Work in
/home/jwoltje/src/mosaic-stack-worktrees/gate-001 - Do not merge or deploy
- Must pass:
pnpm format:checkSKIP_ENV_VALIDATION=true pnpm turbo typecheckSKIP_ENV_VALIDATION=true pnpm turbo lintSKIP_ENV_VALIDATION=true pnpm turbo test --filter=@mosaic/api -- --testPathPattern="gatekeeper"
ASSUMPTION
- Woodpecker PR pipelines expose
CI_COMMIT_PULL_REQUESTandCI_COMMIT_SHA, so the webhook notifier can sendprNumberandheadSha.- Rationale: Gatekeeper needs an exact PR/head tuple to safely match CI back to
pending_merges.
- Rationale: Gatekeeper needs an exact PR/head tuple to safely match CI back to
Plan
- Add Prisma model + SQL migration for
pending_merges - Add Gatekeeper NestJS module/controller/service/DTO/tests
- Wire Woodpecker webhook -> Gatekeeper CI handler
- Add env/config documentation and compose variables
- Run quality gates, review, remediate, push, open PR
Progress
- Context loaded
- Tests added first
- Implementation complete
- Quality gates green
- Push + PR opened
Verification
- Pending