I have setup the follow Laravel Cronjob command:
protected function schedule(Schedule $schedule)
{
$schedule->command('DataDownloader:downloaddata')->dailyAt('19:34');
}
This saves some data from an API into a mySQL database. The command is listed under php artisan
and I am able to run it using php artisan DataDownloader:downloaddata
.
I have added the Cron entry to my crontab
as per Laravel documentation:
* * * * * php /var/www/html/myprojectname/artisan schedule:run >> /dev/null 2>&1
When I run php artisan schedule:run
it tells me 'No scheduled commands are ready to run'. I don't really know if this suggests if my Cronjob does not work at all or it is just broken.
Am I missing something or did I do something wrong that prevents the Cron from running?
My server is running Ubuntu with NGINX.