GithubHelp home page GithubHelp logo

ota1-letzgame / nodequery-server Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cnly1987/nodequery-server

0.0 1.0 0.0 29.28 MB

nodequery server

License: MIT License

Python 2.02% HTML 0.68% JavaScript 91.00% CSS 4.21% SCSS 1.92% Shell 0.16%

nodequery-server's Introduction

nodequery-server

介绍

nodequery-server 基于nodequery.com的开源客户端开发的服务端。

软件架构

python3 django3 mysql mongodb celery

演示

演示地址:http://www.monitorx.xyz/ Alt text Alt text Alt text

安装流程

  1. 安装python3,pip3
  2. 克隆项目代码,或者下载ZIP解压
  3. 安装依赖:pip -r requirement.txt
  4. 安装mysql(>=5.7),mongodb(>=4.2)
  5. 配置项目录下nqmonitor/setting.py 根据注释填写mysql和mongodb的信息,注意数据库名为nqmonitor
  6. 安装gunicorn和supervisor,配置django 进程守护
  7. 安装nginx并配置gunicorn代理

具体部署

以centos7为例, 作为服务端,服务器建议2H4G以上。如果是你的监控的服务器比较小,可以选择1H1G的。
  1. 安装lnmp,具体见:https://lnmp.org/install.html, 本步骤只是为了安装nginx/mysql环境,可以用yum或者其他类似面板替代如(BT,AMH等)
  2. 安装python3,pip3, 具体可以参考https://blog.csdn.net/qq_36357820/article/details/89631712
  3. 克隆本项目或者下载ZIP解压到 你的目录,比如/home/wwwroot/
  4. 在项目目录下安装依赖,执行 pip -r requirement.txt, 或者安装pipenv创建虚拟ENV
  5. 在mysql和mongodb中创建数据库nqmonitor.
  6. 在项目目录下nqmonitor/setting.py中 填写mysql数据库账号密码,以及mongodb账号密码,文件中有如何填写的注释。
  7. 执行python manage.py makemigrations
  8. 执行python manage.py migrate 创建mysql表
  9. 执行python manage.py createsuperuser 创建超级用户。
  10. 安装gunicron 执行:pip install gunicron
  11. 安装supervisor 执行:pip install supervisor
  12. 配置supervisor 守护django 进程, supervisor教程:http://www.awkxy.com/Linux/supervisor.html
  13. 配置nginx反代,绑定域名
  14. 完工

备注

  1. 安装脚本在/static/sh 目录下,请把域名替换成你的域名。
  2. 首页代码在templates/index.html 需要修改的自行编辑
  3. 修改网站名称的,请前往 templates/layout/base.html

nodequery-server's People

Contributors

awkxy avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.