Cron job may be setup by module file etc/crontab.xml, that will have such content.

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Cron:etc/crontab.xsd">
   <group id="default">
       <job name="download_expire_link" instance="Web4pro\Download\Model\Cron" method="execute">
           <schedule>0 1 * * *</schedule>
       </job>
   </group>
</config>

Class Web4pro\Download\Model\Cron should exist and implement method execute, that will run, when cron job starts.

5.00 / 5.0
Article rating (6 Reviews)
Do you find this article useful? Please, let us know your opinion and rate the post!
Not badGoodVery GoodGreatAwesome