# customer_service **Repository Path**: ywq_1992/customer_service ## Basic Information - **Project Name**: customer_service - **Description**: 这是一个客服在线聊天的系统 - **Primary Language**: PHP - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 3 - **Forks**: 1 - **Created**: 2021-04-14 - **Last Updated**: 2025-05-03 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # customer_service #### 介绍 使用了swoole原生开发的客服聊天的系统,由于2019的时候使用的swoole4.4.16,所以大家在安装swoole版本的时候需要注意一下兼容问题 #### 环境 ``` 1.mysql5.7 2.redis3.2.12 3.php7.2.27 4.nginx1.16.1 ``` #### php扩展安装 ``` 1.swoole4.4.16 #编译时候开启openssl 2.yum install -y ImageMagick ImageMagick-devel # 安装imagemagick 3.pecl install imagick #安装imagick3.4.4扩展 4.extension=imagick.so #修改php.ini, 添加扩展 5.swoole.enable_library = off #关闭默认的swoole类包 6.安装mcrypt1.0.3扩展 ``` #### 使用说明 使用systemd 来管理swoole的后台运行 vim /etc/systemd/system/swoole-kf.service加入以下代码 ``` [Unit] Description= Ehco Websocket Server After=network.target After=syslog.target [Service] Type=simple LimitNOFILE=65535 ExecStart=/usr/bin/php /www/wwwroot/kf-system/service > runtime.log [p] #p用来表示为生产环境,默认为dev ExecReload=/bin/kill -USR1 $MAINPID Restart=always [Install] WantedBy=multi-user.target graphical.target ``` 保存之后使用systemctl daemon-reload 重载一下 #### 服务管理 ``` systemctl start swoole-kf #启动 systemctl stop swoole-kf #停止 systemctl restart swoole-kf #重启服务 systemctl reload swoole-kf #重载服务 ``` #### 参与贡献