Kernel.php 770 B

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. namespace App\Console;
  3. use Illuminate\Console\Command;
  4. use Illuminate\Console\Scheduling\Schedule;
  5. use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
  6. class Kernel extends ConsoleKernel
  7. {
  8. /**
  9. * The Artisan commands provided by your application.
  10. *
  11. * @var array
  12. */
  13. protected $commands = [
  14. Commands\Inspire::class,
  15. 'App\Console\Commands\LogTask',
  16. ];
  17. /**
  18. * Define the application's command schedule.
  19. *
  20. * @param \Illuminate\Console\Scheduling\Schedule $schedule
  21. * @return void
  22. */
  23. protected function schedule(Schedule $schedule)
  24. {
  25. $schedule->command('inspire')->hourly();
  26. $schedule->command('log:task --force')->everyMinute();
  27. }
  28. }