Guest User

Untitled

a guest
Dec 5th, 2018
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.91 KB | None | 0 0
  1. ##################### Grafana Configuration Example #####################
  2. #
  3. # Everything has defaults so you only need to uncomment things you want to
  4. # change
  5.  
  6. # possible values : production, development
  7. ;app_mode = production
  8.  
  9. # instance name, defaults to HOSTNAME environment variable value or hostname if HOSTNAME var is empty
  10. ;instance_name = ${HOSTNAME}
  11.  
  12. #################################### Paths ####################################
  13. [paths]
  14. # Path to where grafana can store temp files, sessions, and the sqlite3 db (if that is used)
  15. ;data = /var/lib/grafana
  16.  
  17. # Temporary files in `data` directory older than given duration will be removed
  18. ;temp_data_lifetime = 24h
  19.  
  20. # Directory where grafana can store logs
  21. ;logs = /var/log/grafana
  22.  
  23. # Directory where grafana will automatically scan and look for plugins
  24. ;plugins = /var/lib/grafana/plugins
  25.  
  26. # folder that contains provisioning config files that grafana will apply on startup and while running.
  27. ;provisioning = conf/provisioning
  28.  
  29. #################################### Server ####################################
  30. [server]
  31. # Protocol (http, https, socket)
  32. ;protocol = http
  33.  
  34. # The ip address to bind to, empty will bind to all interfaces
  35. ;http_addr =
  36.  
  37. # The http port to use
  38. ;http_port = 3000
  39.  
  40. # The public facing domain name used to access grafana from a browser
  41. ;domain = localhost
  42.  
  43. # Redirect to correct domain if host header does not match domain
  44. # Prevents DNS rebinding attacks
  45. ;enforce_domain = false
  46.  
  47. # The full public facing url you use in browser, used for redirects and emails
  48. # If you use reverse proxy and sub path specify full url (with sub path)
  49. ;root_url = http://localhost:3000
  50.  
  51. # Log web requests
  52. ;router_logging = false
  53.  
  54. # the path relative working path
  55. ;static_root_path = public
  56.  
  57. # enable gzip
  58. ;enable_gzip = false
  59.  
  60. # https certs & key file
  61. ;cert_file =
  62. ;cert_key =
  63.  
  64. # Unix socket path
  65. ;socket =
  66.  
  67. #################################### Database ####################################
  68. [database]
  69. # You can configure the database connection by specifying type, host, name, user and password
  70. # as separate properties or as on string using the url properties.
  71.  
  72. # Either "mysql", "postgres" or "sqlite3", it's your choice
  73. ;type = sqlite3
  74. ;host = 127.0.0.1:3306
  75. ;name = grafana
  76. ;user = root
  77. # If the password contains # or ; you have to wrap it with triple quotes. Ex """#password;"""
  78. ;password =
  79.  
  80. # Use either URL or the previous fields to configure the database
  81. # Example: mysql://user:secret@host:port/database
  82. ;url =
  83.  
  84. # For "postgres" only, either "disable", "require" or "verify-full"
  85. ;ssl_mode = disable
  86.  
  87. # For "sqlite3" only, path relative to data_path setting
  88. ;path = grafana.db
  89.  
  90. # Max idle conn setting default is 2
  91. ;max_idle_conn = 2
  92.  
  93. # Max conn setting default is 0 (mean not set)
  94. ;max_open_conn =
  95.  
  96. # Connection Max Lifetime default is 14400 (means 14400 seconds or 4 hours)
  97. ;conn_max_lifetime = 14400
  98.  
  99. # Set to true to log the sql calls and execution times.
  100. log_queries =
  101.  
  102. #################################### Session ####################################
  103. [session]
  104. # Either "memory", "file", "redis", "mysql", "postgres", default is "file"
  105. ;provider = file
  106.  
  107. # Provider config options
  108. # memory: not have any config yet
  109. # file: session dir path, is relative to grafana data_path
  110. # redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=grafana`
  111. # mysql: go-sql-driver/mysql dsn config string, e.g. `user:password@tcp(127.0.0.1:3306)/database_name`
  112. # postgres: user=a password=b host=localhost port=5432 dbname=c sslmode=disable
  113. ;provider_config = sessions
  114.  
  115. # Session cookie name
  116. ;cookie_name = grafana_sess
  117.  
  118. # If you use session in https only, default is false
  119. ;cookie_secure = false
  120.  
  121. # Session life time, default is 86400
  122. ;session_life_time = 86400
  123.  
  124. #################################### Data proxy ###########################
  125. [dataproxy]
  126.  
  127. # This enables data proxy logging, default is false
  128. ;logging = false
  129.  
  130. #################################### Analytics ####################################
  131. [analytics]
  132. # Server reporting, sends usage counters to stats.grafana.org every 24 hours.
  133. # No ip addresses are being tracked, only simple counters to track
  134. # running instances, dashboard and error counts. It is very helpful to us.
  135. # Change this option to false to disable reporting.
  136. ;reporting_enabled = true
  137.  
  138. # Set to false to disable all checks to https://grafana.net
  139. # for new vesions (grafana itself and plugins), check is used
  140. # in some UI views to notify that grafana or plugin update exists
  141. # This option does not cause any auto updates, nor send any information
  142. # only a GET request to http://grafana.com to get latest versions
  143. ;check_for_updates = true
  144.  
  145. # Google Analytics universal tracking code, only enabled if you specify an id here
  146. ;google_analytics_ua_id =
  147.  
  148. #################################### Security ####################################
  149. [security]
  150. # default admin user, created on startup
  151. ;admin_user = admin
  152.  
  153. # default admin password, can be changed before first start of grafana, or in profile settings
  154. ;admin_password = admin
  155.  
  156. # used for signing
  157. ;secret_key = SW2YcwTIb9zpOOhoPsMm
  158.  
  159. # Auto-login remember days
  160. ;login_remember_days = 7
  161. ;cookie_username = grafana_user
  162. ;cookie_remember_name = grafana_remember
  163.  
  164. # disable gravatar profile images
  165. ;disable_gravatar = false
  166.  
  167. # data source proxy whitelist (ip_or_domain:port separated by spaces)
  168. ;data_source_proxy_whitelist =
  169.  
  170. # disable protection against brute force login attempts
  171. ;disable_brute_force_login_protection = false
  172.  
  173. #################################### Snapshots ###########################
  174. [snapshots]
  175. # snapshot sharing options
  176. ;external_enabled = true
  177. ;external_snapshot_url = https://snapshots-origin.raintank.io
  178. ;external_snapshot_name = Publish to snapshot.raintank.io
  179.  
  180. # remove expired snapshot
  181. ;snapshot_remove_expired = true
  182.  
  183. #################################### Dashboards History ##################
  184. [dashboards]
  185. # Number dashboard versions to keep (per dashboard). Default: 20, Minimum: 1
  186. ;versions_to_keep = 20
  187.  
  188. #################################### Users ###############################
  189. [users]
  190. # disable user signup / registration
  191. ;allow_sign_up = true
  192.  
  193. # Allow non admin users to create organizations
  194. ;allow_org_create = true
  195.  
  196. # Set to true to automatically assign new users to the default organization (id 1)
  197. ;auto_assign_org = true
  198.  
  199. # Default role new users will be automatically assigned (if disabled above is set to true)
  200. ;auto_assign_org_role = Viewer
  201.  
  202. # Background text for the user field on the login page
  203. ;login_hint = email or username
  204.  
  205. # Default UI theme ("dark" or "light")
  206. ;default_theme = dark
  207.  
  208. # External user management, these options affect the organization users view
  209. ;external_manage_link_url =
  210. ;external_manage_link_name =
  211. ;external_manage_info =
  212.  
  213. # Viewers can edit/inspect dashboard settings in the browser. But not save the dashboard.
  214. ;viewers_can_edit = false
  215.  
  216. [auth]
  217. # Set to true to disable (hide) the login form, useful if you use OAuth, defaults to false
  218. ;disable_login_form = false
  219.  
  220. # Set to true to disable the signout link in the side menu. useful if you use auth.proxy, defaults to false
  221. ;disable_signout_menu = false
  222.  
  223. # URL to redirect the user to after sign out
  224. ;signout_redirect_url =
  225.  
  226. #################################### Anonymous Auth ##########################
  227. [auth.anonymous]
  228. # enable anonymous access
  229. ;enabled = false
  230.  
  231. # specify organization name that should be used for unauthenticated users
  232. ;org_name = Main Org.
  233.  
  234. # specify role for unauthenticated users
  235. ;org_role = Viewer
  236.  
  237. #################################### Github Auth ##########################
  238. [auth.github]
  239. ;enabled = false
  240. ;allow_sign_up = true
  241. ;client_id = some_id
  242. ;client_secret = some_secret
  243. ;scopes = user:email,read:org
  244. ;auth_url = https://github.com/login/oauth/authorize
  245. ;token_url = https://github.com/login/oauth/access_token
  246. ;api_url = https://api.github.com/user
  247. ;team_ids =
  248. ;allowed_organizations =
  249.  
  250. #################################### Google Auth ##########################
  251. [auth.google]
  252. ;enabled = false
  253. ;allow_sign_up = true
  254. ;client_id = some_client_id
  255. ;client_secret = some_client_secret
  256. ;scopes = https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email
  257. ;auth_url = https://accounts.google.com/o/oauth2/auth
  258. ;token_url = https://accounts.google.com/o/oauth2/token
  259. ;api_url = https://www.googleapis.com/oauth2/v1/userinfo
  260. ;allowed_domains =
  261.  
  262. #################################### Generic OAuth ##########################
  263. [auth.generic_oauth]
  264. ;enabled = false
  265. ;name = OAuth
  266. ;allow_sign_up = true
  267. ;client_id = some_id
  268. ;client_secret = some_secret
  269. ;scopes = user:email,read:org
  270. ;auth_url = https://foo.bar/login/oauth/authorize
  271. ;token_url = https://foo.bar/login/oauth/access_token
  272. ;api_url = https://foo.bar/user
  273. ;team_ids =
  274. ;allowed_organizations =
  275. ;tls_skip_verify_insecure = false
  276. ;tls_client_cert =
  277. ;tls_client_key =
  278. ;tls_client_ca =
  279.  
  280. #################################### Grafana.com Auth ####################
  281. [auth.grafana_com]
  282. ;enabled = false
  283. ;allow_sign_up = true
  284. ;client_id = some_id
  285. ;client_secret = some_secret
  286. ;scopes = user:email
  287. ;allowed_organizations =
  288.  
  289. #################################### Auth Proxy ##########################
  290. [auth.proxy]
  291. ;enabled = false
  292. ;header_name = X-WEBAUTH-USER
  293. ;header_property = username
  294. ;auto_sign_up = true
  295. ;ldap_sync_ttl = 60
  296. ;whitelist = 192.168.1.1, 192.168.2.1
  297. ;headers = Email:X-User-Email, Name:X-User-Name
  298.  
  299. #################################### Basic Auth ##########################
  300. [auth.basic]
  301. ;enabled = true
  302.  
  303. #################################### Auth LDAP ##########################
  304. [auth.ldap]
  305. ;enabled = false
  306. ;config_file = /etc/grafana/ldap.toml
  307. ;allow_sign_up = true
  308.  
  309. #################################### SMTP / Emailing ##########################
  310. [smtp]
  311. ;enabled = false
  312. ;host = localhost:25
  313. ;user =
  314. # If the password contains # or ; you have to wrap it with trippel quotes. Ex """#password;"""
  315. ;password =
  316. ;cert_file =
  317. ;key_file =
  318. ;skip_verify = false
  319. ;from_address = admin@grafana.localhost
  320. ;from_name = Grafana
  321. # EHLO identity in SMTP dialog (defaults to instance_name)
  322. ;ehlo_identity = dashboard.example.com
  323.  
  324. [emails]
  325. ;welcome_email_on_sign_up = false
  326.  
  327. #################################### Logging ##########################
  328. [log]
  329. # Either "console", "file", "syslog". Default is console and file
  330. # Use space to separate multiple modes, e.g. "console file"
  331. ;mode = console file
  332.  
  333. # Either "debug", "info", "warn", "error", "critical", default is "info"
  334. ;level = info
  335.  
  336. # optional settings to set different levels for specific loggers. Ex filters = sqlstore:debug
  337. ;filters =
  338.  
  339. # For "console" mode only
  340. [log.console]
  341. ;level =
  342.  
  343. # log line format, valid options are text, console and json
  344. ;format = console
  345.  
  346. # For "file" mode only
  347. [log.file]
  348. ;level =
  349.  
  350. # log line format, valid options are text, console and json
  351. ;format = text
  352.  
  353. # This enables automated log rotate(switch of following options), default is true
  354. ;log_rotate = true
  355.  
  356. # Max line number of single file, default is 1000000
  357. ;max_lines = 1000000
  358.  
  359. # Max size shift of single file, default is 28 means 1 << 28, 256MB
  360. ;max_size_shift = 28
  361.  
  362. # Segment log daily, default is true
  363. ;daily_rotate = true
  364.  
  365. # Expired days of log file(delete after max days), default is 7
  366. ;max_days = 7
  367.  
  368. [log.syslog]
  369. ;level =
  370.  
  371. # log line format, valid options are text, console and json
  372. ;format = text
  373.  
  374. # Syslog network type and address. This can be udp, tcp, or unix. If left blank, the default unix endpoints will be used.
  375. ;network =
  376. ;address =
  377.  
  378. # Syslog facility. user, daemon and local0 through local7 are valid.
  379. ;facility =
  380.  
  381. # Syslog tag. By default, the process' argv[0] is used.
  382. ;tag =
  383.  
  384. #################################### Alerting ############################
  385. [alerting]
  386. # Disable alerting engine & UI features
  387. ;enabled = true
  388. # Makes it possible to turn off alert rule execution but alerting UI is visible
  389. ;execute_alerts = true
  390.  
  391. # Default setting for new alert rules. Defaults to categorize error and timeouts as alerting. (alerting, keep_state)
  392. ;error_or_timeout = alerting
  393.  
  394. # Default setting for how Grafana handles nodata or null values in alerting. (alerting, no_data, keep_state, ok)
  395. ;nodata_or_nullvalues = no_data
  396.  
  397. # Alert notifications can include images, but rendering many images at the same time can overload the server
  398. # This limit will protect the server from render overloading and make sure notifications are sent out quickly
  399. ;concurrent_render_limit = 5
  400.  
  401. #################################### Explore #############################
  402. [explore]
  403. # Enable the Explore section
  404. ;enabled = false
  405.  
  406. #################################### Internal Grafana Metrics ##########################
  407. # Metrics available at HTTP API Url /metrics
  408. [metrics]
  409. # Disable / Enable internal metrics
  410. ;enabled = true
  411.  
  412. # Publish interval
  413. ;interval_seconds = 10
  414.  
  415. # Send internal metrics to Graphite
  416. [metrics.graphite]
  417. # Enable by setting the address setting (ex localhost:2003)
  418. ;address =
  419. ;prefix = prod.grafana.%(instance_name)s.
  420.  
  421. #################################### Distributed tracing ############
  422. [tracing.jaeger]
  423. # Enable by setting the address sending traces to jaeger (ex localhost:6831)
  424. ;address = localhost:6831
  425. # Tag that will always be included in when creating new spans. ex (tag1:value1,tag2:value2)
  426. ;always_included_tag = tag1:value1
  427. # Type specifies the type of the sampler: const, probabilistic, rateLimiting, or remote
  428. ;sampler_type = const
  429. # jaeger samplerconfig param
  430. # for "const" sampler, 0 or 1 for always false/true respectively
  431. # for "probabilistic" sampler, a probability between 0 and 1
  432. # for "rateLimiting" sampler, the number of spans per second
  433. # for "remote" sampler, param is the same as for "probabilistic"
  434. # and indicates the initial sampling rate before the actual one
  435. # is received from the mothership
  436. ;sampler_param = 1
  437.  
  438. #################################### Grafana.com integration ##########################
  439. # Url used to import dashboards directly from Grafana.com
  440. [grafana_com]
  441. ;url = https://grafana.com
  442.  
  443. #################################### External image storage ##########################
  444. [external_image_storage]
  445. # Used for uploading images to public servers so they can be included in slack/email messages.
  446. # you can choose between (s3, webdav, gcs, azure_blob, local)
  447. ;provider =
  448.  
  449. [external_image_storage.s3]
  450. ;bucket =
  451. ;region =
  452. ;path =
  453. ;access_key =
  454. ;secret_key =
  455.  
  456. [external_image_storage.webdav]
  457. ;url =
  458. ;public_url =
  459. ;username =
  460. ;password =
  461.  
  462. [external_image_storage.gcs]
  463. ;key_file =
  464. ;bucket =
  465. ;path =
  466.  
  467. [external_image_storage.azure_blob]
  468. ;account_name =
  469. ;account_key =
  470. ;container_name =
  471.  
  472. [external_image_storage.local]
  473. # does not require any configuration
  474.  
  475. [rendering]
  476. # Options to configure external image rendering server like https://github.com/grafana/grafana-image-renderer
  477. ;server_url =
  478. ;callback_url =
Add Comment
Please, Sign In to add comment