import { Module } from '@nestjs/common'; import { PipelinesResolver } from './pipelines.resolver'; import { PipelinesService } from './pipelines.service'; import { TypeOrmModule } from '@nestjs/typeorm'; import { Pipeline } from './pipeline.entity'; import { CommitLogsResolver } from './commit-logs.resolver'; import { PipelineTasksModule } from '../pipeline-tasks/pipeline-tasks.module'; import { ReposModule } from '../repos/repos.module'; import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq'; import { ConfigModule, ConfigService } from '@nestjs/config'; import { CommonsModule } from '../commons/commons.module'; @Module({ imports: [ CommonsModule, TypeOrmModule.forFeature([Pipeline]), PipelineTasksModule, RabbitMQModule.forRootAsync(RabbitMQModule, { imports: [ConfigModule], useFactory: (configService: ConfigService) => ({ uri: configService.get('db.rabbitmq.uri'), exchanges: [], }), inject: [ConfigService], }), ], providers: [PipelinesResolver, PipelinesService, CommitLogsResolver], }) export class PipelinesModule {}