config.sample.js 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. /** @scratch /configuration/config.js/1
  2. * == Configuration
  3. * config.js is where you will find the core Grafana configuration. This file contains parameter that
  4. * must be set before Grafana is run for the first time.
  5. */
  6. define(['settings'],
  7. function (Settings) {
  8. "use strict";
  9. return new Settings({
  10. /**
  11. * elasticsearch url:
  12. * For Basic authentication use: http://username:password@domain.com:9200
  13. */
  14. elasticsearch: "http://"+window.location.hostname+":9200",
  15. /**
  16. * graphite-web url:
  17. * For Basic authentication use: http://username:password@domain.com
  18. * Basic authentication requires special HTTP headers to be configured
  19. * in nginx or apache for cross origin domain sharing to work (CORS).
  20. * Check install documentation on github
  21. */
  22. graphiteUrl: "http://"+window.location.hostname+":8080",
  23. /**
  24. * Multiple graphite servers? Comment out graphiteUrl and replace with something like this:
  25. datasources: {
  26. data_center_us: {
  27. type: 'graphite',
  28. url: 'http://<graphite_url>',
  29. default: true
  30. },
  31. data_center_eu: {
  32. type: 'graphite',
  33. url: 'http://<graphite_url>',
  34. render_method: 'GET' // optional, use this to change render calls from POST to GET
  35. }
  36. },
  37. */
  38. default_route: '/dashboard/file/default.json',
  39. /**
  40. * If you experiance problems with zoom, it is probably caused by timezone diff between
  41. * your browser and the graphite-web application. timezoneOffset setting can be used to have Grafana
  42. * translate absolute time ranges to the graphite-web timezone.
  43. * Example:
  44. * If TIME_ZONE in graphite-web config file local_settings.py is set to America/New_York, then set
  45. * timezoneOffset to "-0500" (for UTC - 5 hours)
  46. * Example:
  47. * If TIME_ZONE is set to UTC, set this to "0000"
  48. */
  49. timezoneOffset: null,
  50. /**
  51. * Elasticsearch index for storing dashboards
  52. *
  53. */
  54. grafana_index: "grafana-dash",
  55. /**
  56. * set to false to disable unsaved changes warning
  57. */
  58. unsaved_changes_warning: true,
  59. panel_names: [
  60. 'text',
  61. 'graphite'
  62. ]
  63. });
  64. });