您现在的位置是:首页> 编程文章 个人博客模板
laravel队列守护进程
无痕小Q个人博客
2021-04-20 11:03:52【
主页】
1762人已围观
简介队列守护进程
1:安装supervisor
yum install supervisor
2:配置supervisor
[include]
files=/etc/supervisor/conf.d/*.conf
//新增的 Supervisor 配置文件放在 /etc/supervisor/conf.d/ 目录下,并且以 conf 结尾。
配置
[program:laravel-worker]
process_name=%(program_name)s_%(process_num)02d
command=php /usr/share/nginx/html/yzc136.cn/artisan queue:work
autostart=true
autorestart=true
user=root
#运行几个进程
numprocs=3
redirect_stderr=true
#日志记入地址
stdout_logfile=/usr/share/nginx/html/yzc136.cn-laravel-work.log
3:启动
// 开机自启动
systemctl enable supervisord
// 重启
systemctl enable supervisord
// 运行状态
systemctl status supervisord
当然了,还可以使用宝塔快速配置
1:安装

2:配置

启动队列 php artisan queue:work
其他参数根据个人需求配置
3:启动

也可以指定php版本
阅读量! (1762)
点击排行
风回岂复坚。 明月易低人易散,归来呼酒更重看。
网站公告
- 欢迎来到我的博客
1:欢迎来到我的博客
2:博客免费api接口现已上线
3:博客会定期更新文章
4:欢迎大家来捧场
站点信息
千里黄云白日曛,北风吹雁雪纷纷。
莫愁前路无知己,天下谁人不识君。
- 建站时间:2019-8-30
- 网站程序:php,laravel-swoole框架
- 今日流量:799(10分钟统计一次)
- 本月流量:10879
- 浏览总量:604999
- 统计方式:中间件,redis消息队列,定时任务
申请链接友情链接
生活是一位睿智的长者,生活是一位博学的老师,它常常春风化雨,润物无声地为我们指点迷津,给我们人生的启迪。