- Run
composer require omnilight/yii2-schedulingto install the scheduling package - Setup a
config/schedule.phpfile to house your scheduled processes - Modify your
config/app.phpto include theschedulecomponent details to run the Craft command (instead ofyii) - Run
php craft schedule/run --scheduleFile=@config/schedule.phpto process any scheduled operations.
💡 Tip: You likely want to run php craft schedule/run --scheduleFile=@config/schedule.php on a cron job that fires every minute!