Skip to content

Instantly share code, notes, and snippets.

@sabcio
Created October 29, 2014 07:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sabcio/aaa9489502116192dcac to your computer and use it in GitHub Desktop.
Save sabcio/aaa9489502116192dcac to your computer and use it in GitHub Desktop.
Grafana config file
///// @scratch /configuration/config.js/1
// == Configuration
// config.js is where you will find the core Grafana configuration. This file contains parameter that
// must be set before Grafana is run for the first time.
///
define(['settings'],
function (Settings) {
return new Settings({
// datasources, you can add multiple
datasources: {
'grafana':{
type: 'influxdb',
url: "http://127.0.0.1:8086/db/grafana",
username: 'root',
password: 'root',
grafanaDB: true
},
'metrics': {
type: 'influxdb',
url: 'http://127.0.0.1:8086/db/graphite',
username: 'root',
password: 'root',
default: true
}
},
// elasticsearch url
// used for storing and loading dashboards, optional
// For Basic authentication use: http://username:password@domain.com:9200
// elasticsearch: '/elasticsearch', //"http://"+window.location.hostname+":9200",
// default start dashboard
default_route: '/dashboard/file/default.json',
// Elasticsearch index for storing dashboards
grafana_index: "grafana-dash",
// timezoneOFfset:
// If you experiance problems with zoom, it is probably caused by timezone diff between
// your browser and the graphite-web application. timezoneOffset setting can be used to have Grafana
// translate absolute time ranges to the graphite-web timezone.
// Example:
// If TIME_ZONE in graphite-web config file local_settings.py is set to America/New_York, then set
// timezoneOffset to "-0500" (for UTC - 5 hours)
// Example:
// If TIME_ZONE is set to UTC, set this to "0000"
//
timezoneOffset: 0200,
// set to false to disable unsaved changes warning
unsaved_changes_warning: true,
// set the default timespan for the playlist feature
// Example: "1m", "1h"
playlist_timespan: "1m",
// Add your own custom pannels
plugins: {
panels: []
}
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment