move api to separate repository

This commit is contained in:
Pravdin Egor
2023-09-06 12:22:05 +07:00
commit 02e9f874da
43 changed files with 981 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
import { DataSource } from 'typeorm';
import { ConfigService } from '@nestjs/config';
import { config } from 'dotenv';
config();
const configService = new ConfigService();
export default new DataSource({
type: 'postgres',
host: configService.get('DB_HOST'),
port: +configService.get('DB_PORT'),
username: configService.get('DB_USER'),
password: configService.get('DB_PASSWORD'),
database: configService.get('DB_NAME'),
entities: ['dist/**/*.entity.js'],
migrations: ['migrations/**/*'],
});