Code Monkey home page Code Monkey logo

opsgenie-real-time-alert-view's Introduction

OpsGenie Real-Time Alert View

Demo of a Real-Time Alert Dashboard by tracking OpsGenie Alert API & WebHook

Installing npm

a package manager for JavaScript http://www.npmjs.com

npm is bundled with Node.js http://nodejs.org/download

Installing Bower

a package manager for the Web http://bower.io

$ npm install -g bower

Installing project dependencies

# install dependencies listed in bower.json
$ cd web
$ bower install
# install dependencies listed in package.json
$ cd lambda
$ npm install

Configuring project

All required configuration options are listed under

/web/resources/js/configure.js
/lambda/index.js
  • Create PubNub account, and create application on the PubNub Dashboard.
  • Change "publishKey = "<PUBNUB_PUBLISH_KEY"" parameter in the "/lambda/index.js" with your newly created application publish_key.
  • Change "subscribeKey = "<PUBNUB_SUBSCRIBE_KEY>"" parameter in the "/lambda/index.js" with your newly created application subscribe_key.
  • Change "SubscribeKey: "pubnub-subscribe-key"" parameter in the "/web/resources/js/configure.js" with your newly created application subscribe_key.
  • Change "Channel: "pubnub-channel"" parameter in the "/web/resources/js/configure.js" with a channel name you want.
  • Change "channelId = "<PUBNUB_CHANNEL>"" parameter in the "/lambda/index.js" with the channel name you typed earlier.
  • Change "key: "opsgenie-web-api-key"" parameter in the "/web/resources/js/configure.js" with the API Integration key you have on your OpsGenie Application.

Deploying Lambda Function

  • Select index.js and node_modules folder and compress as .ZIP file.
  • Create Funtion on AWS Lambda Console
  • Upload .ZIP file from Code Tab on Lambda Console.
  • On the Api endpoints tab, add API endpoint with { API endpoint type: API Gateway, Method: OPTIONS, Security: Open } parameters and submit.
    • Replace "url: "aws-gateway-url"" parameter in the /web/resources/js/configure.js file with Api endpoint URL.
    • To enable CORS, on the AWS Gateway Console, add Header Mappings on the Integrations Response tab.
      • Add Header: Access-Control-Allow-Headers => 'Content-Type,X-Amz-Date,Authorization'
      • Add Header: Access-Control-Allow-Methods => 'GET,POST,OPTIONS'
      • Add Header: Access-Control-Allow-Origin => '*'
  • On the Api endpoints tab, add API endpoint with { API endpoint type: API Gateway, Method: POST, Security: Open } parameters and submit.
    • To receive notifications from OpsGenie, add OpsGenie Webhook Integration on OpsGenie integrations page and fill URL parameter with Api endpoint URL.

Deploying Web Project

  • Web project contains pure HTML/JavaScript code. Deploy all web folder content to your favorite HTTP Server.

Browser Compatibility

  • Chrome 5+
  • Internet Explorer 9+
  • Firefox 29+
  • Safari 5.1+
  • Opera 10.5+

opsgenie-real-time-alert-view's People

Contributors

kaanbasal avatar

Watchers

James Cloos avatar RoyB 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.