How to create and monitor scheduled tasks in Laravel applications

A quick guide on how to create cron jobs in a Laravel application and easily monitor them.

Tigran Hakobyan
May 15, 2018 · 5 min read


Creating a new task

SendDailyDigest class generated for us
Changing the signature and description of the command
The handle() method where all the command logic lives

Scheduling the task

Starting the scheduler on your server

Monitoring your task with Cronhub

Cronhub’s home page
Cronhub’s “Edit Monitor” page
adding thenPing() method to the task schedule
Cronhub dashboard shows all your monitors and their statuses

Tigran Hakobyan

Written by

Software engineer @buffer. Creator of Interested in writing and developer productivity. Previously @twitter.