| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- <?php
- namespace App\Console;
- use App\Console\Anime\AnimeCheckImgUrlCommand;
- use App\Console\Anime\SegmentCheckAudioCommand;
- use App\Console\Test\RegisterUserCommand;
- use Illuminate\Console\Scheduling\Schedule;
- use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
- class Kernel extends ConsoleKernel
- {
- protected $commands = [
- Test\TestCommand::class,
- RegisterUserCommand::class,
- AnimeCheckImgUrlCommand::class,
- Commands\ProcessImageGenerationQueueCommand::class,
- SegmentCheckAudioCommand::class
- ];
- /**
- * Define the application's command schedule.
- *
- * @param \Illuminate\Console\Scheduling\Schedule $schedule
- * @return void
- */
- protected function schedule(Schedule $schedule)
- {
- // 检查图片生成任务状态
- $schedule->command('AIGeneration:checkImgTasks')->everyMinute();
-
- // 检查视频生成任务状态
- $schedule->command('AIGeneration:checkVideoTasks')->everyMinute();
- // 检查动漫对话图片生成状态
- $schedule->command('Anime:checkImgUrl')->everyMinute();
- // 检查分镜音频生成状态
- $schedule->command('Segment:checkAudio')->everyMinute();
-
- // 处理图片生成任务队列
- $schedule->command('image-generation:process-queue')->everyMinute();
- }
- /**
- * Register the commands for the application.
- *
- * @return void
- */
- protected function commands()
- {
- $this->load(__DIR__ . '/Commands');
- require base_path('routes/console.php');
- }
- }
|