6402f802e9
- Generate Drizzle migrations (databases/migrations/) - Add databases/schema.kit.ts for drizzle-kit (Node-compatible imports) - Update drizzle.config.ts to use schema.kit.ts - Add deno tasks: test:unit, test:integration, migrate - Add tests/helpers/db_integration.ts: testDb, truncateAll, seed helpers - Add .gitea/workflows/test.yml: CI with postgres service container - Update lint.yml: run test:unit only (no DB needed) - Update deploy.yml: add check-code job, gate deploy on it
16 lines
447 B
TypeScript
16 lines
447 B
TypeScript
import { defineConfig } from "drizzle-kit";
|
|
import process from "node:process";
|
|
|
|
export default defineConfig({
|
|
dialect: "postgresql",
|
|
schema: "./databases/schema.kit.ts",
|
|
out: "./databases/migrations",
|
|
dbCredentials: {
|
|
host: process.env.POSTGRES_HOST!,
|
|
port: Number(process.env.POSTGRES_PORT ?? 5432),
|
|
user: process.env.POSTGRES_USER!,
|
|
password: process.env.POSTGRES_PASS!,
|
|
database: process.env.POSTGRES_DB!,
|
|
},
|
|
});
|