2024-07-14 20:25:52 -04:00
|
|
|
import { Module } from '@nestjs/common';
|
|
|
|
import { AppController } from './app.controller';
|
|
|
|
import { AppService } from './app.service';
|
2024-07-15 14:17:40 -04:00
|
|
|
import { ConfigModule } from '@nestjs/config';
|
|
|
|
import config from './config/config';
|
|
|
|
import { MailModule } from './mail/mail.module';
|
2024-07-18 21:59:27 -04:00
|
|
|
import { RedisModule } from './redis/redis.module';
|
|
|
|
import { OpenTelemetryModule } from 'nestjs-otel';
|
2024-07-14 20:25:52 -04:00
|
|
|
|
|
|
|
@Module({
|
2024-07-15 14:17:40 -04:00
|
|
|
imports: [
|
2024-07-18 21:59:27 -04:00
|
|
|
OpenTelemetryModule.forRoot({
|
|
|
|
metrics: {
|
|
|
|
apiMetrics: {
|
|
|
|
enable: true,
|
|
|
|
ignoreRoutes: [
|
|
|
|
'/favicon.ico',
|
|
|
|
'/OidcServiceWorker.js',
|
|
|
|
'/swagger',
|
|
|
|
'/swagger-json',
|
|
|
|
'/swagger-yaml',
|
|
|
|
'/swagger/(.*)',
|
|
|
|
'/metrics',
|
|
|
|
'/interaction/(.*}',
|
|
|
|
],
|
|
|
|
ignoreUndefinedRoutes: true,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}),
|
2024-07-15 14:17:40 -04:00
|
|
|
ConfigModule.forRoot({
|
|
|
|
cache: true,
|
|
|
|
isGlobal: true,
|
|
|
|
load: [config],
|
|
|
|
}),
|
|
|
|
MailModule,
|
2024-07-18 21:59:27 -04:00
|
|
|
RedisModule,
|
|
|
|
|
2024-07-15 14:17:40 -04:00
|
|
|
],
|
2024-07-14 20:25:52 -04:00
|
|
|
controllers: [AppController],
|
|
|
|
providers: [AppService],
|
|
|
|
})
|
|
|
|
export class AppModule {}
|