您现在的位置是:首页> 编程文章 个人博客模板
laravel队列守护进程
无痕小Q个人博客
2021-04-20 11:03:52【
主页】
1529人已围观
简介队列守护进程
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版本
阅读量! (1529)
点击排行
尚未佩妥剑,转眼便江湖。愿历尽千帆,归来仍少年。
网站公告
- 欢迎来到我的博客
1:欢迎来到我的博客
2:博客免费api接口现已上线
3:博客会定期更新文章
4:欢迎大家来捧场
站点信息
由于性格太内向,一直做不出抢着结账这种事。
- 建站时间:2019-8-30
- 网站程序:php,laravel-swoole框架
- 今日流量:0(10分钟统计一次)
- 本月流量:0
- 浏览总量:458502
- 统计方式:中间件,redis消息队列,定时任务
申请链接友情链接
渭城朝雨浥轻尘,客舍青青柳色新。
劝君更尽一杯酒,西出阳关无故人。