Skip to content

Commit 400ca07

Browse files
initialize User module and package
1 parent 3a5046e commit 400ca07

File tree

4 files changed

+6
-16
lines changed

4 files changed

+6
-16
lines changed
File renamed without changes.

src/app.module.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ import { AppController } from './app.controller';
33
import { AppService } from './app.service';
44
import { TypeOrmModule } from '@nestjs/typeorm';
55
import { ConfigModule } from '@nestjs/config';
6-
import configuration from 'src/config/config';
6+
import { UsersModule } from './module/users/users.module';
7+
import configuration from '../config/config';
78

89
@Module({
910
imports: [
@@ -22,6 +23,7 @@ import configuration from 'src/config/config';
2223
entities: [],
2324
synchronize: true,
2425
}),
26+
UsersModule,
2527
],
2628
controllers: [AppController],
2729
providers: [AppService],

src/main.ts

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,9 @@ import { AppModule } from './app.module';
33
import * as cookieParser from 'cookie-parser';
44
import * as bodyParser from 'body-parser';
55
import * as compression from 'compression';
6-
import fs from 'fs';
7-
import path from 'path';
86

97
async function bootstrap() {
10-
const ssl = process.env.SSL === 'true';
11-
let httpsOptions = null;
12-
if (ssl) {
13-
const keyPath = process.env.SSL_KEY_PATH || '';
14-
const certPath = process.env.SSL_CERT_PATH || '';
15-
httpsOptions = {
16-
key: fs.readFileSync(path.join(__dirname, keyPath)),
17-
cert: fs.readFileSync(path.join(__dirname, certPath)),
18-
};
19-
}
20-
21-
const app = await NestFactory.create(AppModule, { httpsOptions });
8+
const app = await NestFactory.create(AppModule);
229

2310
app.setGlobalPrefix('api');
2411
app.use(bodyParser.json({ limit: '10000mb' }));

tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
{
22
"compilerOptions": {
3+
"types": ["node", "@types/jest"],
34
"module": "commonjs",
45
"declaration": true,
56
"removeComments": true,
67
"emitDecoratorMetadata": true,
78
"experimentalDecorators": true,
89
"allowSyntheticDefaultImports": true,
9-
"target": "ES2021",
10+
"target": "es2017",
1011
"sourceMap": true,
1112
"outDir": "./dist",
1213
"baseUrl": "./",

0 commit comments

Comments
 (0)