Update:弃用通知书
php artisan queue:work -h
--daemon Run the worker in daemon mode (Deprecated)
运行queue:work
会自动产生一个守护进程.不再需要旗帜.
对我来说,它使用Redis作为队列驱动程序,并在web
进程之外设置一个队列worker
进程.
My Procfile then looks like this:
web: vendor/bin/heroku-php-apache2 public/
worker: php artisan queue:work redis --sleep=3 --tries=3 --daemon
I don't really know if this is the way one should go, but it works for now.
Edit:
Note, that you are starting up another dyno here, so if you are not using the free tier on Heroku it's double the price now.