Giter VIP home page Giter VIP logo

webhook-shims's Introduction

Build Status https://coveralls.io/repos/github/vmw-loginsight/webhook-shims/badge.svg?branch=master

Translation Shims for Log Insight and/or vRealize Operations Manager Webhooks

Translate webhooks from Log Insight 3.3+ and vRealize Operations Manager 6.0+ (recommended 6.2+) to other services. Get alerts in your team chatroom, open an incident ticket or kick off a remediation workflow.

Log Insight and vRealize Operations Manager send alert notifications as HTTP POST with a JSON body. However, most third-party solutions expect incoming webhooks to be in a proprietary format. If the receiving system lacks native support for the webhook format, a shim between them can translate the webhook format as needed. This repository provides several example shims design to work with Python 2.7+.

Installation

Three installation methods exist. Please select the one you are most comfortable with.

docker run -it -p 5001:5001 vmware/webhook-shims
tdnf install wget -y
wget https://bootstrap.pypa.io/get-pip.py
python get-pip.py
pip install virtualenv
tdnf install git -y
virtualenv loginsightwebhookdemo
cd loginsightwebhookdemo
source bin/activate
git clone https://github.com/vmw-loginsight/webhook-shims.git
cd webhook-shims/
pip install -r requirements.txt
tdnf install wget python2 python2-xml -y
wget https://bootstrap.pypa.io/get-pip.py
python get-pip.py
pip install virtualenv
tdnf install git -y
virtualenv loginsightwebhookdemo
cd loginsightwebhookdemo
source bin/activate
git clone https://github.com/vmw-loginsight/webhook-shims.git
cd webhook-shims/
pip install -r requirements.txt
iptables -A INPUT -p tcp --dport 5001 -j ACCEPT

Manual

virtualenv loginsightwebhookdemo
cd loginsightwebhookdemo
source bin/activate
git clone https://github.com/vmw-loginsight/webhook-shims.git
cd webhook-shims/
pip install -r requirements.txt

Modify and run the shim:

  • Some services require credentials or URLs. Edit individual services under loginsightwebhookdemo/ to modify constants as needed. (Note: For basic auth, ~/.netrc will take prescendence.)
  • Run python runserver.py [port] - the Flask webserver starts and reports listening - default http://0.0.0.0:5001/
  • Open your browser pointed to the Flask webserver for a list of available URLs.

Documentation

Documentation for this shim can be found under the Installation section above. Once the shim is running, documentation for all endpoint can be found at the root path. With the shim running, you need to configure sources to point to the shim. Configuration information for Log Insight and vRealize Operations Manager are listed below.

Log Insight webhook configuration

There are two places in LI where webhooks can be configured:

  1. System notification: under the General page in the Administration section
  2. User alerts: while creating a new user alert or by editing an existing user alert

vRealize Operations Manager webhook configuration

REST plugin: under Administration > Outbound Settings

Developing and Contributing

We’d love to get contributions from you! Once you are up and running, take a look at the Contribution Document to see how to get your changes merged in.

Licensing

Provided under Apache License 2.0. For more information, see the LICENSE file.

Support

Please report problems via GitHub issues.

webhook-shims's People

Contributors

asudhak avatar blackmesaresearch avatar doogleit avatar ellieayla avatar flands avatar h0bbel avatar johnddias avatar prydin avatar vmw-loginsight 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.