Skip to content

宝塔部署 ​

你正在阅读的是 RuoYi AI的文档!

  • 如发现文档有误,欢迎提交 issue 帮助我们改进。

部署后端项目 ​

  1. 使用idea的maven工具,把项目打成jar包 alt text

  2. 创建目录并且上传.jar文件

alt text

  1. 添加java项目

alt text

  1. 启动项目

alt text

部署后台管理项目 ​

  1. 执行打包命令: pnpm run build:antd

alt text

  1. 将dict文件上传至服务器

alt text

  1. 添加站点

alt text

  1. 配置nginx
yaml

    location /prod-api/{
        proxy_pass http://127.0.0.1:6039/; 
        # 避免出现反代https域名出现502错误
        proxy_ssl_server_name on;
        # 设置原始的Host头信息
        proxy_set_header Host $http_host;
    }
    
    # 解决刷新404问题
    #vue-router配置
    location / {
        try_files $uri $uri/ @router;
        index index.html;
    }
    location @router {
        rewrite ^.*$ /index.html last;
    }

部署用户端项目 ​

  1. 执行打包命令:npm run build

alt text

  1. 将dict文件上传至服务器 alt text

  2. 添加站点 alt text

  3. 配置nginx

yaml
    location /api/{
        proxy_pass http://127.0.0.1:6039/; 
        # 避免出现反代https域名出现502错误
        proxy_ssl_server_name on;
        # 关闭缓存实现打字机效果
        proxy_buffering off;
        # 设置原始的Host头信息
        proxy_set_header Host $http_host;
    }

配置安全规则 ​

alt text

腾讯云oss配置 ​

  1. 控制台-对象存储-创建存储桶 alt text

  2. 配置存储桶信息

alt text

alt text

alt text 3. 获取API管密钥

alt text

  1. 后台管理配置密钥信息

alt text 5. 启用配置

alt text

  1. 上传文件验证是否配置成功

alt text

邮箱配置 ​

alt text

alt text

  1. 配置邮箱信息

alt text

安装向量库(weaviate) ​

  1. 将script/docker/weaviate 目录下的yml文件上传至服务器

alt text

  1. 同级目录下执行

alt text

java
{
  "registry-mirrors": [
    "https://mirror.aliyuncs.com",
    "https://docker.registry.cyou",
    "https://docker-cf.registry.cyou",
    "https://dockercf.jsdelivr.fyi",
    "https://docker.jsdelivr.fyi",
    "https://dockertest.jsdelivr.fyi",
    "https://mirror.baidubce.com",
    "https://docker.m.daocloud.io",
    "https://docker.mirrors.ustc.edu.cn",
    "https://mirror.iscas.ac.cn",
    "https://docker.nju.edu.cn",
    "https://docker.rainbond.cc",
    "https://docker.mirrors.sjtug.sjtu.edu.cn",
    "https://b9pmyelo.mirror.aliyuncs.com",
    "https://do.nark.eu.org",
    "https://dc.j8.work",
    "https://docker.m.daocloud.io",
    "https://dockerproxy.com",
    "https://docker.mirrors.ustc.edu.cn",
    "https://docker.nju.edu.cn",
    "https://noohub.ru",
    "https://huecker.io",
    "https://dockerhub.timeweb.cloud",
    "https://registry.dockermirror.com"
  ]
}