Code Monkey home page Code Monkey logo

kumauto's Introduction

Monitoring automation project for Prometheus and ecosystem (in-progress)

One of the main problem that we face with microservices deployment is how to configure monitoring. With deployment being so dynamic its hard to make changes.

As you can see in the blog: https://medium.com/@tomarv2/jenkins-shared-libraries-ab64f7acac68. I discussed how can repos can be arranged and how monitoring jobs at scale can be configured. Most of the work of adding projects to monitoring and alerting was manual.

In this project we are trying to offload the management of monitoring and alerting. When a new project is added, user adds/updates user_input.yaml and it will be picked up by CICD (in this case Jenkins).

Where will the monitoring be configured:

  • Prometheus
  • Blackbox
  • Elastalert
  • Pushgateway
  • Pagerduty
  • Email
  • Slack

Pre-reqs:

  • Running Elastalert
  • Running Alertmanager
  • Running Prometheus Monitoring
  • Running Pushgateway
  • Pagerduty account
  • Slack account
  • Kafka/Zookeper (when we wrote this project, we had a requirement to cleanup Kafka/Zookeeper)

Note:

  • Docker image should have ssh keys to connect to git.

How to begin:

To create dummy data for testing:

verify if static-files directory exists:

DIR_NAME=demo1
BASE_PATH='/Users/varun.tomar/Documents/personal_github'

mkdir -p $BASE_PATH/mauto/$DIR_NAME/demo-data/monitoring/static-files

verify if alertmanager config file exists:

mkdir -p $BASE_PATH/mauto/$DIR_NAME/demo-data/alertmanager
cp $BASE_PATH/mauto/data/demo-data/alertmanager/config.yaml $BASE_PATH/mauto/$DIR_NAME/demo-data/alertmanager/config.yaml

verify if prometheus config file exists:

mkdir -p $BASE_PATH/mauto/junk/demo-data/monitoring/
cp $BASE_PATH/mauto/data/demo-data/monitoring/config.yaml $BASE_PATH/mauto/junk/demo-data/monitoring/

verify .env file exists:

Copy the example.env and create a .env file

Update src/automation/config.yaml

How to use?

  • run pip install mauto
  • run muato for available options

Note:

  1. Trying to make it modular or plug and play type so new components can be added easily.

  2. I am using click to create python cli.

  3. Python 3.6 and above is required

kumauto's People

Contributors

dependabot[bot] avatar tomarv2 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  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.