<?php
// app/Console/Kernel.php
protected function schedule(Schedule $schedule)
{
// Using the named helper (Laravel 8+)
$schedule->command('billing:close-month')
->lastDayOfMonth(); // → equivalent to ->cron('0 0 L * *')
// Or with an explicit cron expression
$schedule->command('reports:monthly')
->cron('0 1 L * *') // 01:00 on the last day of every month
->onFailure(function () {
// alerting hook
});
}Laravel's scheduler runs every minute (via a single system cron entry on the server) and dispatches the matching schedule entries. The last-day-of-month job will be picked up correctly because the underlying parser supports L.