# ┌───────────── minute (0 - 59) # │ ┌───────────── hour (0 - 23) # │ │ ┌───────────── day of month (1 - 31) # │ │ │ ┌───────────── month (1 - 12 or JAN-DEC) # │ │ │ │ ┌───────────── day of week (0 - 7 or SUN-SAT, where 0 and 7 = Sunday) # │ │ │ │ │ # * * * * * command_to_execute # Special characters: # * = every possible value # */n = every “n” units (e.g., */10 = every 10 minutes) # , = separate multiple values (e.g., 1,15 = run on the 1st and 15th) # - = define ranges (e.g., 1-5 = Monday to Friday) # Every 3 minutes between 12:00 AM and 2:59 AM: change loan/borrow list status to 'work in progress' */3 0-2 * * * /bin/sh /var/www/html/server/cron/changeloanborrowliststatustoworkinprogress.sh /var/www/html/server # Every 3 minutes between 12:00 AM and 2:59 AM: change loan/borrow list status to 'work done' */3 0-2 * * * /bin/sh /var/www/html/server/cron/changeloanborrowliststatustoworkdone.sh /var/www/html/server # Every 3 minutes between 1:00 AM and 2:59 AM: update expired loan requests */3 1-2 * * * /bin/sh /var/www/html/server/cron/updateexpiredloanrequest.sh /var/www/html/server # Every 3 minutes between 1:00 AM and 2:59 AM: remove unsubmitted company cart entries */3 1-2 * * * /bin/sh /var/www/html/server/cron/removeunsubmittedcompanycart.sh /var/www/html/server # Run queues every minute * * * * * /bin/sh /var/www/html/server/queues/queues_dev.sh # Clear the queues log every 10 minutes */10 * * * * /usr/bin/truncate -s 0 /var/www/html/server/queues/queues.log # Clear the custom cron log every Tuesday at 11:30 PM 30 23 * * 2 /usr/bin/truncate -s 0 /var/www/html/server/cron/logs.log # Clear the Laravel jobs log every Tuesday at 11:30 PM 30 23 * * 2 /usr/bin/truncate -s 0 /var/www/html/server/storage/logs/jobs.log # Run updatecompanysubscriptions.sh every 10 minutes between 12:00 AM and 1:59 AM */10 0-1 * * * /bin/sh /var/www/html/server/cron/updatecompanysubscriptions.sh /var/www/html/server # Run updatecompanymonthlysubscriptions.sh every 10 minutes between 12:00 AM and 1:59 AM */10 0-1 * * * /bin/sh /var/www/html/server/cron/updatecompanymonthlysubscriptions.sh /var/www/html/server # Run updateblockedcompanysubscriptions.sh every 10 minutes between 12:00 AM and 1:59 AM */10 0-1 * * * /bin/sh /var/www/html/server/cron/updateblockedcompanysubscriptions.sh /var/www/html/server # Clear the Let's Encrypt log on the 1st of each month at 12:00 AM 0 0 1 * * /usr/bin/truncate -s 0 /var/log/letsencrypt/letsencrypt.log # Send admin email notification for company usage daily at 11:57 PM 57 23 * * * /bin/sh /var/www/html/server/cron/adminemailnotifications-company-usage.sh /var/www/html/server # Send admin email notification for company subscription payments daily at 11:58 PM 58 23 * * * /bin/sh /var/www/html/server/cron/adminemailnotifications-companysubscriptionpayment.sh /var/www/html/server # Send admin email notification for newly created companies daily at 11:59 PM 59 23 * * * /bin/sh /var/www/html/server/cron/adminemailnotifications-newlycreatedcompanies.sh /var/www/html/server # Run everyfifteendays.sh on the 1st and 15th of each month at 1:00 AM 00 01 1,15 * * /bin/sh /var/www/html/server/cron/everyfifteendays.sh /var/www/html/server # Run daily-cron.sh hourly at 1 minute past the hour 1 * * * * /bin/sh /var/www/html/server/cron/daily-cron.sh /var/www/html/server # Change to the Laravel project directory and run the Laravel task scheduler once daily at 12:00 AM (midnight). # The "php artisan schedule:run" command checks Laravel's internal schedule and executes any due tasks # defined in app/Console/Kernel.php. Output and errors are redirected to /dev/null to prevent logging. 0 0 * * * cd /var/www/html/server && php artisan schedule:run >> /dev/null 2>&1