claude drizzle integration
This commit is contained in:
12
src/db/index.ts
Normal file
12
src/db/index.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { drizzle } from 'drizzle-orm/postgres-js';
|
||||
import postgres from 'postgres';
|
||||
import * as schema from './schema';
|
||||
|
||||
const connectionString = process.env.DATABASE_URL!;
|
||||
|
||||
const client = postgres(connectionString, {
|
||||
prepare: false,
|
||||
connect_timeout: 30,
|
||||
idle_timeout: 30,
|
||||
});
|
||||
export const db = drizzle(client, { schema });
|
||||
Reference in New Issue
Block a user