We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b4c22ba commit d6ed1f1Copy full SHA for d6ed1f1
.env.example
@@ -0,0 +1,9 @@
1
+DB_PORT=""
2
+DB_HOST=""
3
+DB_PASSWORD=""
4
+DB_USERNAME=""
5
+DB_NAME=""
6
+
7
+APP_PORT=""
8
9
+JWT_SECRET=""
README.md
@@ -0,0 +1 @@
+uses postgres
src/main.ts
@@ -1,13 +1,15 @@
import dotenv from 'dotenv';
dotenv.config();
+import env from './common/config';
import { ValidationPipe } from '@nestjs/common';
import { NestFactory } from '@nestjs/core';
import { AppModule } from './app.module';
10
async function bootstrap() {
11
const app = await NestFactory.create(AppModule);
12
app.useGlobalPipes(new ValidationPipe());
- await app.listen(3000);
13
+ await app.listen(env.APP_PORT);
14
}
15
bootstrap();
0 commit comments