generated from fahricansecer/boilerplate-be
This commit is contained in:
@@ -2,6 +2,7 @@ import { Module } from '@nestjs/common';
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import { APP_FILTER, APP_GUARD, APP_INTERCEPTOR } from '@nestjs/core';
|
||||
import { ThrottlerModule, ThrottlerGuard } from '@nestjs/throttler';
|
||||
import { BullModule } from '@nestjs/bullmq';
|
||||
import { CacheModule } from '@nestjs/cache-manager';
|
||||
import { redisStore } from 'cache-manager-redis-yet';
|
||||
import { LoggerModule } from 'nestjs-pino';
|
||||
@@ -40,6 +41,14 @@ import { AdminModule } from './modules/admin/admin.module';
|
||||
import { HealthModule } from './modules/health/health.module';
|
||||
import { GeminiModule } from './modules/gemini/gemini.module';
|
||||
|
||||
// Video SaaS Modules
|
||||
import { ProjectsModule } from './modules/projects/projects.module';
|
||||
import { VideoQueueModule } from './modules/video-queue/video-queue.module';
|
||||
import { VideoAiModule } from './modules/video-ai/video-ai.module';
|
||||
import { StorageModule } from './modules/storage/storage.module';
|
||||
import { BillingModule } from './modules/billing/billing.module';
|
||||
import { XTwitterModule } from './modules/x-twitter/x-twitter.module';
|
||||
|
||||
// Guards
|
||||
import {
|
||||
JwtAuthGuard,
|
||||
@@ -65,6 +74,19 @@ import {
|
||||
],
|
||||
}),
|
||||
|
||||
// BullMQ — Redis tabanlı job kuyruğu (Video üretim pipeline)
|
||||
BullModule.forRootAsync({
|
||||
imports: [ConfigModule],
|
||||
useFactory: (configService: ConfigService) => ({
|
||||
connection: {
|
||||
host: configService.get<string>('redis.host', 'localhost'),
|
||||
port: configService.get<number>('redis.port', 6379),
|
||||
password: configService.get<string>('redis.password') || undefined,
|
||||
},
|
||||
}),
|
||||
inject: [ConfigService],
|
||||
}),
|
||||
|
||||
// Logger (Structured Logging with Pino)
|
||||
LoggerModule.forRootAsync({
|
||||
imports: [ConfigModule],
|
||||
@@ -160,6 +182,14 @@ import {
|
||||
// Optional Modules (controlled by env variables)
|
||||
GeminiModule,
|
||||
HealthModule,
|
||||
|
||||
// Video SaaS Modules
|
||||
ProjectsModule,
|
||||
VideoQueueModule,
|
||||
VideoAiModule,
|
||||
StorageModule,
|
||||
BillingModule,
|
||||
XTwitterModule,
|
||||
],
|
||||
providers: [
|
||||
// Global Exception Filter
|
||||
|
||||
Reference in New Issue
Block a user