# SpeedCheck-backend **Repository Path**: HughNew/speed-check-backend ## Basic Information - **Project Name**: SpeedCheck-backend - **Description**: 速查后端 vuepress模板见 - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2022-03-13 - **Last Updated**: 2022-07-31 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 速查系统服务端 > **\*nix only(macOS included)** 所必须的文件相对位置 ``` ├── flask-server └── www ``` flask-server 为 Flask应用所在文件夹 文件夹名无所谓 www 为 VuePress 文件所在位置 (**如需更改** 需要同时更改 vuepressUtil.py 中 全局变量) ## 服务端部署 服务器部署使用 - uWSGI - 依赖 gcc - nginx 拉取代码:`git clone https://gitee.com/HughNew/speed-check-backend.git` 或者通过下载压缩包方式(压缩包地址:) 具体部署参考这里: ### nginx配置 除了uWSGI的nginx反向代理配置外 还需要配置Web静态资源的访问 配置如下 ```nginx server { listen 80 default_server; listen [::]:80 default_server; root /path/to/www/html; # /www/html 这部分不能改 前面 /path/to 需要更改 index index.html; location / { # First attempt to serve request as file, then # as directory, then fall back to displaying a 404. try_files $uri $uri/ =404; } } ``` ## Web端部署 > nodejs yarn的安装可以在官方文档查看各自系统的安装方式 这里不作讲解 Web端部署使用 - nodejs - yarn - vuepress@next 在服务端的上级目录 打开终端 ```bash git clone https://github.com/HughClub/Vuepress-Template.git www yarn install ``` ## 启动项目 1. 完成nginx配置 2. 启动nginx 3. 启动uWSGI 此时访问 80 端口可以使用Web端 最开始没有报告是正常的 因为没有数据不会生成报告 ## 数据格式定义 客户端向 `/report/