# 基于宝塔面板的安装
## **非[“淘宝Joomla一站通店铺”](https://item.taobao.com/item.htm?spm=a1z10.1-c-s.w5003-23029558665.60.7108c9302k8xnf&id=602703817186&scene=taobao_shop)购买的 迎客客服系统 没有服务 、 没有售后、没有更新 谨防上当受骗**
安装教程是Linux服务器、centos7.6操作系统、宝塔环境(Nginx 1.18.0、Mysql5.7、PHP7.3),Window服务器需要防火墙放行443,788,2080,9090端口(相关教程请百度一下)
要求服务器环境:php版本>=5.6 mysql>=5.6
# 添加站点
![](https://img.kancloud.cn/31/bf/31bf5536850f9939d641c712b49c58a3_779x740.png)
# 解压上传代码
将获取的源码包直接上传到站点文件夹
![](https://img.kancloud.cn/4d/85/4d854d4c8feeab8637ba3fa50300ead4_710x507.png)
![](https://img.kancloud.cn/33/aa/33aa8cf06f067eedb136095d56cc917d_774x547.png)
# 站点设置
![](https://img.kancloud.cn/fe/e9/fee9d6b13c819fd13088c86a5e7045b3_955x654.png)
# 宝塔防火墙配置
开启2080和9090端口
![](https://img.kancloud.cn/f7/60/f76029a81055db75da1c2267109ba877_815x557.png)
![](https://img.kancloud.cn/42/cb/42cbeda54e9cb08dfbb7278e5f3f7553_1021x626.png)
![](https://img.kancloud.cn/b9/51/b9519aa0ce0660d8b3535e16d89a2800_923x424.png)
![](https://img.kancloud.cn/4d/48/4d48f13f48dea7b49d344ca420ed116b_674x339.png)
![](https://img.kancloud.cn/91/0c/910c697e271fc22d6fe004bcf59f36bf_725x676.png)
![](https://img.kancloud.cn/bf/f1/bff18d560f16663483f20addd72b71a5_919x571.png)
![](https://img.kancloud.cn/19/e4/19e466f37b0d590515c46bdf602d12cb_746x443.png)
![](https://img.kancloud.cn/de/df/dedfc1681f2eaacad08f25c6117f4354_844x897.png)
# 伪静态设置
**NGINX配置如下**
Nginx伪静态规则使用如下规则
~~~
location / {
location ~ ^/(upload|assets)/.*\.(php|php5|jsp)$ {deny all;return 404;
}
if (!-e $request_filename){
rewrite ^(.*)$ /index.php?s=$1 last; break;
}
}
~~~
![](https://img.kancloud.cn/88/74/887450c01814519b2ced8273414ad09b_786x784.png)
**Apache配置如下**
Apache伪静态规则使用如下规则
~~~
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?s=/$1 [QSA,PT,L]
</IfModule>
~~~
![](https://img.kancloud.cn/63/4c/634ccabb7c022ce95a431cd4f1a0c57a_696x663.png)
# 安装系统
访问网址`http://你的域名/install.php`进入安装程序:
![](https://img.kancloud.cn/f3/f7/f3f7af4f052827ee78ff3130fb9d6e47_725x906.png)
![](https://img.kancloud.cn/d0/bb/d0bbd13a9cbde2620993fbd75aedbe73_708x908.png)
数据库信息
Host:数据库服务器的IP,如果数据库和站点是同一服务器则可填写`127.0.0.1`或`localhost`;
Database name:您的数据库名称;
Username:对应数据库的用户名;
Password:数据库的密码;
超级管理员注册
Username:管理中心超级用户账号
Password:管理中心超级用户密码
服务器端口配置
App\_key:推送服务的app\_key(一般默认即可)
App\_secret:推送服务的app\_secret(一般默认即可)
App\_id: 推送服务的app\_id(一般默认即可)
websocket 地址:推送服务的websocket地址(自动获取,一般默认即可)
Api地址:推送服务器的api地址(自动获取,一般默认即可)
websocket 端口:推送服务的websocket端口(自定义,没有被占用的端口,注意:防火墙必须允许该端口)
Api端口:推送服务的api端口号(自定义,没有被占用的端口,注意:防火墙必须允许该端口)
registToken:默认即可
* * *
安装成功页面:
![](https://img.kancloud.cn/d8/b3/d8b3ae84ecf3a3a561845c67c94d12f0_724x265.png)
# 开启推送服务
[进入项目xingekefu.com/ymwl\_pusherr目录,打开终端]
![](https://img.kancloud.cn/28/13/2813b6bfefcc7071a3775608566f9134_1133x579.png)
![](https://img.kancloud.cn/96/69/96690bbac446016cc0678f1f68d6fae7_849x624.png)
![](https://img.kancloud.cn/42/3d/423d53ff2fd53ce6e40ed9aa4d6d4714_1269x613.png)
执行 php start.php start -d
![](https://img.kancloud.cn/81/a3/81a3216c9c3993b2ec55465df12c632e_1042x430.png)
![](https://img.kancloud.cn/c0/d3/c0d33eda7d1be341d3950b00bf258f38_783x300.png)
出现上图代表服务开启成功。
如果没有出现上图,一般是由于宝塔版本不同导致初始目录不同,需要先手动切换到\\ymwl\_pusher目录下。
Linux命令如下:
~~~
cd /www/wwwroot/你的实际项目目录/ymwl_pusher/
~~~
# 服务器安全组配置
如果您的服务器是阿里云或腾讯云的服务器,需要配置安全组,**公网入方向和出方向**都允许2080和9090端口
![](https://img.kancloud.cn/bd/3d/bd3dac6a5cf362a6342b7c37a0aff479_1145x513.png)
![](https://img.kancloud.cn/fc/91/fc914c1d9a758adabb8db18904582f97_939x299.png)
**至此程序安装完成,感谢使用,如有安装不成功的朋友欢迎到[“淘宝Joomla一站通店铺”](https://item.taobao.com/item.htm?spm=a1z10.1-c-s.w5003-23029558665.60.7108c9302k8xnf&id=602703817186&scene=taobao_shop)咨询,掌柜会在第一时间解决问题,谢谢!**