I have a problem with migrating laravel to another server, I currently have laravel + redis of which I have some functions in the site cache on redis, the problem is the following, the site works in the other server, but the command schedule:run does not work in cronjob, I tried to run it manually, but it gives me back "No scheduled commands are ready to run" when on the first server runs correctly, the second server is ubuntu 16.04, there is something special to do when changing server? attached I enclose the kernel.php
The old server has Centos 7 Running MariaDB 10.1, PHP 7.2 and NGINX
The new has Ubuntu 16.04 Running MariaDB 10.1, PHP 7.2 and NGINX
namespace App\Console;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
/**
* The Artisan commands provided by your application.
*
* @var array
*/
protected $commands = [
'\App\Console\Commands\CacheSideBar',
'\App\Console\Commands\DailyReset',
'\App\Console\Commands\WeeklyReset',
'\App\Console\Commands\MonthlyReset',
];
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
//$schedule->command('cache:sidebar');
$schedule->command('reset:daily')
->daily()
->withoutOverlapping();
$schedule->command('reset:weekly')
->weeklyOn(1, '00:00')
->withoutOverlapping();
$schedule->command('reset:monthly')
->monthlyOn(1, '00:00')
->withoutOverlapping();
$schedule->command('cache:sidebar')
->everyTenMinutes()
->withoutOverlapping();
}
/**
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
$this->load(__DIR__.'/Commands');
require base_path('routes/console.php');
}
}