# Healthy **Repository Path**: zhangshunping123/Healthy ## Basic Information - **Project Name**: Healthy - **Description**: golang healthy检测服务,支持Hook,Email通知 - **Primary Language**: Go - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2020-05-09 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Healthy #### 介绍 Healthy是一个通过golang语言写的服务健康检测服务,发现连续报错之后会通过ssh协议,链接指定的主机上执行Hook指令。同时根据用户自定义,开关Email邮件通知(故障报警,恢复通知,报警冷却)。 #### 软件架构 #### 软件架构 - Appservice 服务注册,检测,执行Hook - Sshconnect ssh模块 - Email 报警邮件 ##### Hook操作函数: - 执行cmd命令 - 执行通知事件 #### 安装教程 ```shell git clone https://gitee.com/zhangshunping123/Healthy.git go build -o healthy -i main.go chmod +x healthy mv healthy /usr/bin/ ``` #### 使用说明 ```shell mkdir -p ~/.health/ cp config.json ~/.health/ $ ./main.exe -h Usage of C:\Users\39295\Desktop\Healthy\main.exe: -c string Configfile for service health detection (default "~/.health/config.json") -e int Number of consecutive health test failures (default 10) -h help -i int Health check interval (default 2) ``` #### 需要补充 - hook interface化 - 多种 通知方式接入 - 视图友好