2022-06-29 09:23:07 +00:00
|
|
|
import { Module } from '@nestjs/common';
|
|
|
|
import { MongooseModule } from '@nestjs/mongoose';
|
2022-07-25 04:38:48 +00:00
|
|
|
import { ClientsModule, Transport } from '@nestjs/microservices';
|
2022-06-29 09:23:07 +00:00
|
|
|
import { UsersModule } from './users/users.module';
|
|
|
|
|
|
|
|
@Module({
|
|
|
|
imports: [
|
|
|
|
ClientsModule.register([
|
|
|
|
{
|
2022-07-25 04:38:48 +00:00
|
|
|
name: 'SERVICIO_USUARIOS',
|
2022-06-29 09:23:07 +00:00
|
|
|
transport: Transport.TCP,
|
|
|
|
options: {
|
2022-07-25 04:38:48 +00:00
|
|
|
host: '127.0.0.1',
|
|
|
|
port: 3001,
|
|
|
|
},
|
|
|
|
},
|
2022-06-29 09:23:07 +00:00
|
|
|
]),
|
2022-07-25 04:38:48 +00:00
|
|
|
MongooseModule.forRoot(
|
2022-07-27 21:54:31 +00:00
|
|
|
`mongodb+srv://proyecto_4:proyecto_4@proyecto4.yv4fb.mongodb.net/servicio_usuarios?retryWrites=true&w=majority`
|
|
|
|
|
2022-07-25 04:38:48 +00:00
|
|
|
),
|
|
|
|
UsersModule,
|
|
|
|
],
|
2022-06-29 09:23:07 +00:00
|
|
|
controllers: [],
|
|
|
|
providers: [],
|
|
|
|
})
|
2022-07-27 21:54:31 +00:00
|
|
|
export class AppModule { }
|