您现在的位置是:首页> 编程文章 个人博客模板
laravel队列守护进程
无痕小Q个人博客
2021-04-20 11:03:52【
主页】
1516人已围观
简介队列守护进程
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版本
阅读量! (1516)
点击排行
养活我啊,嗯,我觉得,能带我吃饭就好了。
网站公告
- 欢迎来到我的博客
1:欢迎来到我的博客
2:博客免费api接口现已上线
3:博客会定期更新文章
4:欢迎大家来捧场
站点信息
剑外忽传收蓟北,初闻涕泪满衣裳。 却看妻子愁何在,漫卷诗书喜欲狂。 白日放歌须纵酒,青春作伴好还乡。 即从巴峡穿巫峡,便下襄阳向洛阳。
- 建站时间:2019-8-30
- 网站程序:php,laravel-swoole框架
- 今日流量:602(10分钟统计一次)
- 本月流量:28316
- 浏览总量:454757
- 统计方式:中间件,redis消息队列,定时任务
申请链接友情链接
青山横北郭,白水绕东城。
此地一为别,孤蓬万里征。
浮云游子意,落日故人情。
挥手自兹去,萧萧班马鸣。