go2hal

command module
v0.0.0-...-fb315dc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2019 License: MIT Imports: 1 Imported by: 0

README

go2hal

Codacy Badge

Description

GO 2 Hal is a devops automation telegram bot which automates a number of repetitive tasks, while also providing the team with insight into your systems.

The bot consists of a number of individual models, so if you want to create your own bot, its as simple as creating your main.go and choosing the modules.

the main.go provided here uses all the modules, wrapped in gokit proetheus instrumenting and gokit logging.

Refer to the readme.md for each Module

Getting Started

Simply Configure the environment variables and execute main.go

At present, HAL uses Mongo has its datastore.

Important Environment Variables
Telegram

BOT_KEY - The key from botfather. Required.

Mongo

If Mongo is running on localhost via the standard port and no authentiation, then the mongo environment variables has be left blank

XRay

If you want to instrument your application with Amazon AWS Xray

  • XRAY_URL - XRAL Daemon URL. Optional
  • XRAY_SAMPLING_RULES - Location of a XRay Sampling JSON File. Optional

Modules

Reffer to the README.md within each of the subdirectories for more details on the module

Telegram Service

Provides a service to send telegram messages and images to groups

Alert Service

Extends upon the Telegram Service to abstract the taget group of a message. Curently the following resful services are provided.

  • Alert Messages
  • Alert Images
  • Error Messages
  • Error Images
Appdynamics

Allows App Dyanmics to send alert messages Monitor MQ Queues via App Dynamics Execute commands based on App Dynamics Alerts

Callout

Invoke Callout by quering a web app to see who is on callout sends SNMP traps creates JIRA tickets

Chef

Alows Chef Delivery to send Alerts Get Nodes based upon recipe and environment

Database

Mongo Database capability

gokit

Some common gokit wrappers

halSelenium

a wrapper to make writting of selenium tests easier

http

monitor http endpoints and alert when the endpoints fail

jira

create JIRA tickets

kubernetes

Sample files to deploy the bot in kubernetes

Remote Telegram Commands

allows a remote program to register a telegram command, for example "/someCommand", on the bot. When the command is executed a grpc call is made back to the system that requetsed the command.

Selenium Tests

periodically execute the selenium tests and alert on error

Sensu

Handle sensu alerts

skynet

an internal module to rebuild nodes

snmp

Send SNMP alerts

SSH

execute SSH commands on a remote server fetch data via SFTP

Documentation

Overview

Package classification GO2HAL API.

Terms Of Service:

there are no TOS at this moment, use at your own risk we take no responsibility

Schemes: http
Version: 0.0.1
License: MIT http://opensource.org/licenses/MIT
Contact: Marc Arndt<marc@marcarndt.com> http://www.marcarndt.com
Title: go2hal API

Consumes:
- application/json

Produces:
- application/json
SecurityDefinitions:
ApiKeyAuth:
   type: apiKey
   in: header
   name: Authorization

swagger:meta

Directories

Path Synopsis
Package mock_alert is a generated GoMock package.
Package mock_alert is a generated GoMock package.
Package mock_analytics is a generated GoMock package.
Package mock_analytics is a generated GoMock package.
Package appdynamics is a generated GoMock package.
Package appdynamics is a generated GoMock package.
Package callout provides a mechanism to invoke various different forms of callout depending on the services linked when creating the service.
Package callout provides a mechanism to invoke various different forms of callout depending on the services linked when creating the service.
Package mock_chef is a generated GoMock package.
Package mock_chef is a generated GoMock package.
Package firstcall is a generated GoMock package.
Package firstcall is a generated GoMock package.
mock_selenium
Package mock_selenium is a generated GoMock package.
Package mock_selenium is a generated GoMock package.
Package halaws is a generated GoMock package.
Package halaws is a generated GoMock package.
Package jira is a generated GoMock package.
Package jira is a generated GoMock package.
Package machineLearning is a generated GoMock package.
Package machineLearning is a generated GoMock package.
Package telegram is a generated protocol buffer package.
Package telegram is a generated protocol buffer package.
mock_remoteTelegramCommands
Package mock_remoteTelegramCommands is a generated GoMock package.
Package mock_remoteTelegramCommands is a generated GoMock package.
Package snmp is a generated GoMock package.
Package snmp is a generated GoMock package.
Package ssh is a generated GoMock package.
Package ssh is a generated GoMock package.
Package mock_telegram is a generated GoMock package.
Package mock_telegram is a generated GoMock package.
Package user is a generated GoMock package.
Package user is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL