This package provides a psr-log adapter for JobRunner.
composer require job-runner/psr-log-adapter
<?php
declare(strict_types=1);
use JobRunner\JobRunner\Job\CliJob;
use JobRunner\JobRunner\Job\JobList;
use JobRunner\JobRunner\CronJobRunner;
use JobRunner\JobRunner\PsrLog\PsrLogEventListener;
require 'vendor/autoload.php';
$myLogger = new \Psr\Log\NullLogger();
$jobList = new JobList();
$jobList->push(new CliJob('php ' . __DIR__ . '/tutu.php', '* * * * *'));
CronJobRunner::create()->withEventListener(new PsrLogEventListener($myLogger));->run($jobList);