feat(WHE-29): add v1 accounting schema migration and seed fixtures

This commit is contained in:
2026-03-05 04:13:00 +04:00
parent 27205bc90b
commit b3ae1a51e4
10 changed files with 1841 additions and 2 deletions

View File

@@ -25,6 +25,7 @@ bun run build
bun run db:generate
bun run db:check
bun run db:migrate
bun run db:seed
bun run infra:fmt:check
bun run infra:validate
```

View File

@@ -58,3 +58,12 @@ bun run build
2. Data backfill/cutover
3. Cleanup migration
- Never run `db:push` in production pipelines.
## Rollback notes
- If a migration fails mid-run, stop deploy and inspect `drizzle.__drizzle_migrations` state first.
- For additive migrations in v1, rollback by:
1. Reverting application code to previous release.
2. Leaving additive schema in place (safe default).
- For destructive migrations, require explicit rollback SQL script in the same PR before deploy approval.
- Keep one database backup/snapshot before production migration windows.