• 免费开源的客服系统 Linux 服务器环境安装部署过程


    最近因为项目需要,要找一款在线客服系统集成在 APP 中使用,而且涉及到生意开单,客服系统必须稳定可靠。另外甲方要求,必须支持 Linux 服务器环境。
    我们以 Ubuntu 18.04 为例把安装部署过程分享一下,其它版本的 Linux 安装配置过程大同小异。

    下载升讯威客服系统程序:
    https://go.shengxunwei.com/?linkid=8f710852-a245-4042-aa28-507a0dd0aec1

    安装 Nginx

    安装

    sudo apt install -y nginx

    查看运行状态

    service nginx status

    安装 SQL Server 数据库

    安装验证文件

    sudo wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -

    安装 libcurl3

    sudo apt install -y libcurl3

    添加 SQL Server for Linux 下载仓库

    安装 SQL Server for Linux

    sudo apt-get install -y mssql-server

    系统初始化配置

    sudo /opt/mssql/bin/mssql-conf setup

    出现如下选项

    1. Evaluation (free, no production use rights, 180-day limit)
    2. Developer (free, no production use rights)
    3. Express (free)
    4. Web (PAID)
    5. Standard (PAID)
    6. Enterprise (PAID) - CPU Core utilization restricted to 20 physical/40 hyperthreaded
    7. Enterprise Core (PAID) - CPU Core utilization up to Operating System Maximum
    8. I bought a license through a retail sales channel and have a product key to enter.

    选择5,标准版

    提示 Enter the SQL Server system administrator password 时要注意输入的密码要不低于8位,且要包含字母大小写和数字

    安装成功,查看mssql-server 运行状态

    systemctl status mssql-server --no-pager

    安装命令行工具和 unixodbc-dev

    添加仓库地址

    要使 sqlcmd/bcp 能从登陆会话的 bash shell 进行访问,请使用下列命令修改 ~/.bash_profile 文件中的 PATH :

    echo 'export PATH="$PATH:/opt/mssql-tools/bin"' >> ~/.bash_profile

    安装 .Net Core

    安装 apt-transport-https

    安装过程中请求涉及 https ,需要安装 https 组件 apt-transport-https,命令如下

    sudo apt-get install apt-transport-https

    安装 .Net Core

    安装成功,查看版本信息

    dotnet --version

    创建数据库

    通过命令行登陆

    sqlcmd -S localhost -U SA

    初始化数据库

    • create database kf;
    • go;

    退出命令行窗口,输入如下语句导入 SQL 文件创建数据库表结构

    sqlcmd -i /你的路径/CreateDatabase.sql -d kf -U sa

    配置服务器主程序

    配置参数

    参考:https://docs.shengxunwei.com/Post/f7bc8496-14ee-4a53-07b4-08d8e3da6269/27f49c5c-61f9-42b8-b086-6bc5326f66e8

    启动程序

    sudo nohup dotnet Sheng.Linkup.Server.dll urls=http://localhost:5000 >/dev/null 2>&1 &

    配置 Nginx 代理

    打开 /etc/nginx/sites-available/default 文件,在 server 节点平级添加如下内容:

    upstream dotnet_server_proxy {                                                         
        server localhost:5000;                                                
        keepalive 2000;
    }
    
    server{
          listen 8080;
          listen [::]:8080;
    
          server_name dotnet_server;
    
          locatiiom / {
                     proxy_pass http://dotnet_server_proxy;
                     proxy_http_version 1.1;
                     proxy_set_header Upgrade $http_upgrade;
                     proxy_set_header Connection keep-alive; 
                     proxy_set_header Host $host;
                     proxy_cache_bypass $http_upgrade;
    
         }
    }
    

    如果绑定域名,将 server_name 后面的 dotnet_server 修改为域名,如:kf-api.shengxunwei.com。listen 监听端口监听改为 80。

    运行

    sudo service nginx reload

    配置服务器资源站点

    配置参数

    参考:https://docs.shengxunwei.com/Post/f7bc8496-14ee-4a53-07b4-08d8e3da6269/2dd5d4a6-9105-4f32-b9b3-240e3354e36d

    配置 Nginx

    修改 Nginx 配置文件:

    sudo vim /etc/nginx/sites-available/default

    如果是用 IP 加端口号的方案,将:

    listen 80 default_server;
    listen [::]:80 default_server;

    修改为

    listen 8081 default_server;
    listen [::]:8081 default_server;

    端口号可根据自己实际更改,如果使用域名则可以跳过这一步骤。

    接下来,将:

    root /var/www/html;

    修改为

    root /你的路径/Resource;

    index index.html

    修改为

    index v.html

    server _;

    修改为

    server 你的域名或ip;

    运行

    sudo service nginx reload

    配置发布客服端程序

    参考:https://docs.shengxunwei.com/Post/f7bc8496-14ee-4a53-07b4-08d8e3da6269/5de7cef6-ac56-4916-b2cd-c1760cd9ae48

    测试

  • 相关阅读:
    如何读入位图(五)
    如何读入位图(四)
    绘制正弦曲线
    图像灰度均衡
    色彩填充及使用
    彩色扇形
    如何读入位图(三)
    ARCGIS FOR SILVERLIGHT Layer
    sqlserver2008多数据库操作(未完)
    SQLSERVER 2008 远程无法连接问题
  • 原文地址:https://www.cnblogs.com/sheng_chao/p/14636129.html
Copyright © 2020-2023  润新知