chore(release): 0.2.17
[risinglegends.git] / knexfile.ts
1 import { config as dotenv } from 'dotenv';
2 import type { Knex } from "knex";
3
4 dotenv();
5 const config: { [key: string]: Knex.Config } = {
6   development: {
7     client: "pg",
8     connection: {
9       database: process.env.PG_DATABASE,
10       user: process.env.PG_USER,
11       password: process.env.PG_PASSWORD
12     },
13     pool: {
14       min: 2,
15       max: 10
16     },
17     migrations: {
18       tableName: "knex_migrations"
19     }
20   },
21
22   production: {
23     client: "pg",
24     connection: {
25       database: process.env.PG_DATABASE,
26       user: process.env.PG_USER,
27       password: process.env.PG_PASSWORD
28     },
29     pool: {
30       min: 2,
31       max: 10
32     },
33     migrations: {
34       tableName: "knex_migrations"
35     }
36   }
37
38 };
39
40 module.exports = config;