make debugger
Deploy / deploy (push) Failing after 14s

This commit is contained in:
Rayyan
2026-08-03 23:33:40 +07:00
parent a5db9d69b3
commit e0bf3882be
4 changed files with 63 additions and 15 deletions
+11 -3
View File
@@ -1,4 +1,5 @@
import { ValidationPipe } from '@nestjs/common';
import { ValidationPipe, Logger } from '@nestjs/common';
import cookieParser from 'cookie-parser';
import { NestFactory } from '@nestjs/core';
import { ConfigService } from '@nestjs/config';
import { DocumentBuilder, SwaggerModule } from '@nestjs/swagger';
@@ -9,6 +10,10 @@ async function bootstrap() {
const app = await NestFactory.create(AppModule);
const config = app.get(ConfigService);
const logger = new Logger('Bootstrap');
// enable cookie parser so req.cookies is populated
app.use(cookieParser());
app.setGlobalPrefix('');
@@ -55,11 +60,14 @@ async function bootstrap() {
SwaggerModule.setup('ApiList', app, document);
}
const port = config.get<number>('PORT') || 3000;
const port = config.get<number>('PORT') || 3000;
logger.log(`Allowed CORS origins: ${JSON.stringify(allowedOrigins)}`);
logger.log(`Server listening on port ${port}`);
await app.listen(port);
console.log(`Server running on http://localhost:${port}`);
logger.log(`Server running on http://localhost:${port}`);
}
bootstrap();