katoikia-app/servicio-foro-comunicaciones/src/main.ts

19 lines
498 B
TypeScript
Raw Normal View History

2022-07-25 04:38:48 +00:00
import { NestFactory } from '@nestjs/core';
import { Transport } from '@nestjs/microservices';
import { AppModule } from './app.module';
import { Logger } from '@nestjs/common';
const logger = new Logger();
2022-07-01 01:44:10 +00:00
async function bootstrap() {
const app = await NestFactory.createMicroservice(AppModule, {
transport: Transport.TCP,
options: {
2022-07-25 04:38:48 +00:00
host: '127.0.0.1',
port: 3007,
},
});
2022-07-25 04:38:48 +00:00
app.listen().then(() => logger.log('Microservice Comunicados is listening'));
2022-07-01 01:44:10 +00:00
}
2022-07-25 04:38:48 +00:00
bootstrap();