mirror of
https://github.com/ahmadk953/poixpixel-discord-bot.git
synced 2025-05-10 02:33:06 +00:00
20 lines
594 B
TypeScript
20 lines
594 B
TypeScript
import fs from 'node:fs';
|
|
import path from 'node:path';
|
|
import { defineConfig } from 'drizzle-kit';
|
|
|
|
const config = JSON.parse(fs.readFileSync('./config.json', 'utf8'));
|
|
const { database } = config;
|
|
|
|
export default defineConfig({
|
|
out: './drizzle',
|
|
schema: './src/db/schema.ts',
|
|
dialect: 'postgresql',
|
|
dbCredentials: {
|
|
url: database.dbConnectionString,
|
|
ssl: {
|
|
ca: fs.readFileSync(path.resolve('./certs/psql-ca.crt')),
|
|
cert: fs.readFileSync(path.resolve('./certs/psql-server.crt')),
|
|
key: fs.readFileSync(path.resolve('./certs/psql-client.key')),
|
|
},
|
|
},
|
|
});
|