feat: fix cron
This commit is contained in:
parent
fdf88b73f5
commit
d91aa3edf9
|
|
@ -1,11 +1,22 @@
|
|||
import { Module } from '@nestjs/common';
|
||||
import { ScheduleModule } from '@nestjs/schedule';
|
||||
import {RefreshTokens} from "@gitroom/cron/tasks/refresh.tokens";
|
||||
import {CheckStars} from "@gitroom/cron/tasks/check.stars";
|
||||
import { RefreshTokens } from '@gitroom/cron/tasks/refresh.tokens';
|
||||
import { CheckStars } from '@gitroom/cron/tasks/check.stars';
|
||||
import { DatabaseModule } from '@gitroom/nestjs-libraries/database/prisma/database.module';
|
||||
import { RedisModule } from '@gitroom/nestjs-libraries/redis/redis.module';
|
||||
import { BullMqModule } from '@gitroom/nestjs-libraries/bull-mq-transport/bull-mq.module';
|
||||
import { ioRedis } from '@gitroom/nestjs-libraries/redis/redis.service';
|
||||
|
||||
@Module({
|
||||
imports: [ScheduleModule.forRoot()],
|
||||
controllers: [],
|
||||
providers: [RefreshTokens, CheckStars],
|
||||
imports: [
|
||||
DatabaseModule,
|
||||
ScheduleModule.forRoot(),
|
||||
RedisModule,
|
||||
BullMqModule.forRoot({
|
||||
connection: ioRedis,
|
||||
}),
|
||||
],
|
||||
controllers: [],
|
||||
providers: [RefreshTokens, CheckStars],
|
||||
})
|
||||
export class CronModule {}
|
||||
|
|
|
|||
Loading…
Reference in New Issue