Giter Club home page Giter Club logo

lemonremotecontrol's Introduction

LemonRemoteControl

项目介绍

基于企业微信、zabbix、ansible的服务器远程操控系统。
已经完成第一期功能:zabbix报警列表,近期会更新第二期功能:服务器操作。

应用场景

  1. zabbix 收到微信报警:tomcat 挂掉了
  2. 打开 柠檬,重启对应tomcat
  3. 服务恢复,收到zabbix ok信息

想想看这样的场景

和女朋友 刚开始前戏,收到一个zabbix报警,这时候爬起来开电脑,岂不是很扫兴,没准还会被女友骂没用

如果有了柠檬就不一样了,拿起手机,都不用拔出来,动动手指解决问题,继续和女友啪啪。

使用方法

企业微信相关:
  1. 注册企业微信 https://work.weixin.qq.com/?from=qyh_redirect
  2. 创建标签,仅允许该标签内的用户访问柠檬系统
  3. 创建应用,设置可见范围,并记录AgentIdSecret
  4. 设置网页授权及JS-SDK,对应你的域名
  5. 设置自定义菜单,跳转到url,比如:
    https://open.weixin.qq.com/connect/oauth2/authorize?appid=dddd&redirect_uri=http%3a%2f%2fwechat.ddddd.com%2flogin%2f&response_type=code&scope=snsapi_privateinfo&agentid=1000002&state=STATE#wechat_redirect
部署应用
  1. 下载应用
git clone https://github.com/X-Mars/LemonRemoteControl.git
pip3.6 install -r requirements.txt
  1. 修改setting.py
WECHAT_SETTING = {
    'corp_id': '222',
    'secret': '222222',
    'agent_id': '1000002',
    'tag_id': '1'
}

ZABBIX_SETTING = {
    'home_url': 'http://zabbix.cn',
    'username': '222',
    'password': '22222'
}
  1. 启动应用
python3.6 LemonRemoteControl/manage.py runserver 0.0.0.0:8000
打开企业微信访问即可

License

996ICU License

lemonremotecontrol's People

Contributors

dependabot[bot] avatar x-mars 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.