Doubt regarding the events of the Task Schedule- Laravel

0

I've already looked in the documentation and other forums, but I did not find the answer.

Next, how often does a task run normally at what time? I know the ->hourly() method runs every hour, but at what time? It runs, for example at 13:00, 14:00, 15:00, etc. Or, depending on the time it was programmed, it can run at, for example, 13:05, 14:05, 15:05, etc.?

    
asked by anonymous 12.12.2018 / 15:31

2 answers

1

The ->hourly(); method runs at the start of each hour. 13: 00,14: 00 etc.

To run at a specific minute there is another method: ->hourlyAt(17);

    
12.12.2018 / 17:55
1

It is based on the crontab (for Linux) that runs every minute:

* * * * * cd /path-to-your-project && php artisan schedule:run >> /dev/null 2>&1

->hourly(); runs every hour of the system, based on what is set in Crontab,

For example when you want to run a script every day at 10:30, just set: ->dailyAt('10:30');

The documentation is very complete, sometimes a bit confusing, follow the link: link

    
12.12.2018 / 18:06