mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-17 11:29:40 +02:00
The media schema/tables were never created on fresh deploys because mana-media only shipped a `db:push` script and nothing ever ran it in the container. Result: every upload returned 500 the moment a new environment came up (just hit prod again on mana.how). - Add `db:generate` + `db:migrate` scripts and a migrate.ts runner - Generate the initial migration covering media/media_references/ media_thumbnails (matches what was already on local + prod, which were stamped manually so the migrator skips on existing deploys) - Call runMigrations() at startup in src/index.ts so future fresh containers self-bootstrap. Idempotent — drizzle tracks state in drizzle.__drizzle_migrations. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| apps/api | ||
| packages/client | ||
| .env.example | ||
| CLAUDE.md | ||
| docker-compose.yml | ||
| drizzle.config.ts | ||
| nest-cli.json | ||
| package.json | ||
| tsconfig.json | ||