katoikia-app/servicio-usuarios/src/users/users.module.ts

27 lines
724 B
TypeScript
Raw Normal View History

2022-06-29 09:23:07 +00:00
import { Module } from '@nestjs/common';
import { UsersService } from './users.service';
import { MongooseModule } from '@nestjs/mongoose';
import { UsersController } from './users.controller';
import { User, UserSchema } from '../schemas/user.schema';
import { ClientsModule, Transport } from "@nestjs/microservices";
2022-06-29 09:23:07 +00:00
@Module({
imports: [
ClientsModule.register([
{
name: "SERVICIO_NOTIFICACIONES",
transport: Transport.TCP,
options: {
host: "127.0.0.1",
port: 3009
}
}
]),
2022-06-29 09:23:07 +00:00
MongooseModule.forFeature([{ name: User.name, schema: UserSchema }]),
],
controllers: [UsersController],
providers: [UsersService]
})
export class UsersModule {}