Giter Club home page Giter Club logo

nr-dash's Introduction

nr-dash

Introduction

nr-dash is a NewRelic dashboard by SurveyMonkey that can be installed, configured and running in under 2 minutes.

Requirements

  • NewRelic account with 'Integrations' enabled

Installation

nr-dash can be installed from node/npm, or by cloning this repository.

npm

  • Type npm install nr-dash
  • Edit config.json and set your API key in key
  • Create a symlink to the app: ln -s node_modules/nr-dash/app.js app.js
  • Type node app.js (stdout & stderr are supported)

git

  • Clone this repository
  • Edit config.json and set your API key in key
  • Configure your webserver to use the /dist folder
  • Configure a route at /config to respond with config.json
  • Optional (if you have node.js installed): skip the step above & type npm install followed by node app.js

How do I get charts?

  • Edit config.json and populate either Applications.metrics.instances[] or Servers.metrics.instances[] with names, e.g. "MyServer-01"
  • Servers.metrics.names[] comes pre-populated, but Applications requires you to fill in metric names; use the NewRelic API explorer to get the metric names

How can I customize the "look & feel"?

  • The static files are found in /dist; css & javascript files are generated!
  • Install node.js & grunt-cli (globally): sudo npm install grunt-cli -g
  • Install ruby sass gem: gem install sass
  • Install development dependencies: npm install
  • Edit /sass/style.scss or any file in /src, save your changes and type grunt to build new assets in /dist
  • Optional: type grunt watch for automatic building upon saving changes to any file used to generate assets

How do I change (name it)?

  • The UI is generated entirely from config.json
  • You can create new dashboard 'pills' by duplicating the Applications or Transactions objects

What can I run this on?

nr-dash has a RWD which allows it to run on practically any device, such as:

  • tablets
  • smartphones
  • laptops / desktops
  • TVs

Configuration

api (string) null

NewRelic API key

colors (array)

Array of chart legend colors

cycle (boolean) false

Cycles dashboard pills

default (string) null

Default pill to load (defaults to first pill if null)

expire (number) 30

DataStore expiration in seconds

hostname (string) localhost

Hostname for the app.js server

pageSize (number) 15

Page size for DataGrids, null to disable pagination

pause (number) 21

Pause between cycles (do not use the same value as expire)

port (number) 8000

Port for the app.js server

si (string) Disk|Memory|Network

Parsed metric names that should be formatted as SI, this is used to generate a RegExp

transition (number) 2

Seconds to animate chart redraw

xformat (string) hh:mm A

X axis tick format, via moment.js

How to make a "pill"

Pills are the name of the dashboard "views", it's just a data abstraction of the interface. nr-dash comes with three predefined pills, but those might not suit your needs, so we made it very easy for you to generate the UI from the data!

To generate a new "pill", follow this template:

{
	"name": "Name in UI",
	"slug": "Slug/Route",
	"source": "Data source in NewRelic API response, usually matches 'name'",
	"uri": "NewRelic API end point",
	"fields": ["keys in API response to display in DataGrid"],
	"order": "SQL like ORDER BY statement of keys in DataGrid",
	"chartGrid": true/false (will generate charts for columns in the DataGrid)
}

If you want charts, add a metrics Object to the pill:

"metrics": {
	"uri": "NewRelic API end point",
	"instances": ["Name of instances to chart"],
	"names": ["Names of metrics to chart"]
}

License

Copyright (c) 2015 SurveyMonkey Licensed under the MIT license.

nr-dash's People

Contributors

avoidwork avatar sciyoshi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

qudini

nr-dash's Issues

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.