I saw that someone else was having the same issue here but when I tried their solution it still does not seem to work.
I am running Laravel 5.7
I have set redis as my cache:
CACHE_DRIVER=redis
but in database.php do I need to edit anything?
'redis' => [
'client' => 'predis',
'default' => [
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'database' => 0,
],
I have done:
composer install predis/predis
I can confirm that redis is working:
KEYS *
1) "laravel:framework/schedule-3032780d7b5657bd5e6ba0fef1359f330895c3da"
I have 15 tasks that run at different times but it seems the first one runs but the others after it do not.
$schedule->command( 'do:task one' )->cron( '1/3 * * * *' )->withoutOverlapping()->runInBackground();
$schedule->command( 'do:task two' )->cron( '1/5 * * * *' )->withoutOverlapping()->runInBackground();
$schedule->command( 'do:task three' )->cron( '1/15 * * * *' )->withoutOverlapping()->runInBackground();
Has anybody else come across this?
Thanks