Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

jeevamugunthan's avatar

laravel queue

Hi, everyone in my laravel application i create an queue for sending mails its working fine , when i deploy the code in server, i create an cron job for run the php artisan queue:work command in cpanel shared hosting. i can't make supervisor for this because of the hosing plan

but the cron job approach is consuming a lot of RAM,

please anyone tell me is there any other way to do this

0 likes
6 replies
Wakanda's avatar

@jeevamugunthan if you have limited server resources and you don't send email frequently u may want to consider removing the worker completely and send emails instantly until u upgrade server resources

CorvS's avatar

@jeevamugunthan

when i deploy the code in server, i create an cron job for run the php artisan queue:work command

What exactly does your cron job do?

jeevamugunthan's avatar

@corvs it runs the php artisan queue:work command for every 30 minutes to run the job for sending emails using database i set the QUEUE_CONNECTION as database

Please or to participate in this conversation.