| name | hr-data-custody |
| description | HR ERP database migrations and packaging: Prisma/SQL surfaces, expand-migrate-contract, RLS-safe seeds, db:verify, distroless/GHCR supply chain. Use for DDL, backfills, dual-write cutovers, Dockerfile, or publish-ghcr workflows. |
| risk | high |
| minRiskTier | T2 |
| source | project |
| disable-model-invocation | true |
HR data custody
Collaboration plane: Specialized skill — invoke only after phase 6 / revalidationConfirmed. Record DDL tradeoffs in collaboration-plan.md.
Use this skill when
- Editing
prisma/schema.prisma, prisma/migrations/**, services/*/db/migrations/**
- Backfills, RLS migrations, or
scripts/db-verify-migration.ts
- Dockerfile, GHCR publish, SBOM/Cosign (ADR 0003)
Do not use this skill when
- Read-only schema questions with no migration intent
- Application code with no DDL/infra change
Instructions
- Read references/migration-runbook.md.
- Apply expand → migrate → contract; CONCURRENTLY discipline for indexes.
- Run
npm run db:verify after migrate deploy in CI/local evidence.
- Co-load
@hr-domain-boundaries when bounded-context SQL changes.
Resources
Limitations
- Zero-downtime posture required for production paths