Add Grafana for displaying time series from Prometheus
[bottlenecks.git] / monitor / grafana / config / grafana.ini
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 #
16 ;data = /var/lib/grafana
17 #
18 # Directory where grafana can store logs
19 #
20 ;logs = /var/log/grafana
21 #
22 # Directory where grafana will automatically scan and look for plugins
23 #
24 ;plugins = /var/lib/grafana/plugins
25
26 #
27 #################################### Server ####################################
28 [server]
29 # Protocol (http, https, socket)
30 ;protocol = http
31
32 # The ip address to bind to, empty will bind to all interfaces
33 ;http_addr =
34
35 # The http port  to use
36 ;http_port = 3000
37
38 # The public facing domain name used to access grafana from a browser
39 ;domain = localhost
40
41 # Redirect to correct domain if host header does not match domain
42 # Prevents DNS rebinding attacks
43 ;enforce_domain = false
44
45 # The full public facing url you use in browser, used for redirects and emails
46 # If you use reverse proxy and sub path specify full url (with sub path)
47 ;root_url = http://localhost:3000
48
49 # Log web requests
50 ;router_logging = false
51
52 # the path relative working path
53 ;static_root_path = public
54
55 # enable gzip
56 ;enable_gzip = false
57
58 # https certs & key file
59 ;cert_file =
60 ;cert_key =
61
62 # Unix socket path
63 ;socket =
64
65 #################################### Database ####################################
66 [database]
67 # You can configure the database connection by specifying type, host, name, user and password
68 # as seperate properties or as on string using the url propertie.
69
70 # Either "mysql", "postgres" or "sqlite3", it's your choice
71 ;type = sqlite3
72 ;host = 127.0.0.1:3306
73 ;name = grafana
74 ;user = root
75 # If the password contains # or ; you have to wrap it with trippel quotes. Ex """#password;"""
76 ;password =
77
78 # Use either URL or the previous fields to configure the database
79 # Example: mysql://user:secret@host:port/database
80 ;url =
81
82 # For "postgres" only, either "disable", "require" or "verify-full"
83 ;ssl_mode = disable
84
85 # For "sqlite3" only, path relative to data_path setting
86 ;path = grafana.db
87
88 # Max conn setting default is 0 (mean not set)
89 ;max_idle_conn =
90 ;max_open_conn =
91
92
93 #################################### Session ####################################
94 [session]
95 # Either "memory", "file", "redis", "mysql", "postgres", default is "file"
96 ;provider = file
97
98 # Provider config options
99 # memory: not have any config yet
100 # file: session dir path, is relative to grafana data_path
101 # redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=grafana`
102 # mysql: go-sql-driver/mysql dsn config string, e.g. `user:password@tcp(127.0.0.1:3306)/database_name`
103 # postgres: user=a password=b host=localhost port=5432 dbname=c sslmode=disable
104 ;provider_config = sessions
105
106 # Session cookie name
107 ;cookie_name = grafana_sess
108
109 # If you use session in https only, default is false
110 ;cookie_secure = false
111
112 # Session life time, default is 86400
113 ;session_life_time = 86400
114
115 #################################### Data proxy ###########################
116 [dataproxy]
117
118 # This enables data proxy logging, default is false
119 ;logging = false
120
121
122 #################################### Analytics ####################################
123 [analytics]
124 # Server reporting, sends usage counters to stats.grafana.org every 24 hours.
125 # No ip addresses are being tracked, only simple counters to track
126 # running instances, dashboard and error counts. It is very helpful to us.
127 # Change this option to false to disable reporting.
128 ;reporting_enabled = true
129
130 # Set to false to disable all checks to https://grafana.net
131 # for new vesions (grafana itself and plugins), check is used
132 # in some UI views to notify that grafana or plugin update exists
133 # This option does not cause any auto updates, nor send any information
134 # only a GET request to http://grafana.com to get latest versions
135 ;check_for_updates = true
136
137 # Google Analytics universal tracking code, only enabled if you specify an id here
138 ;google_analytics_ua_id =
139
140 #################################### Security ####################################
141 [security]
142 # default admin user, created on startup
143 ;admin_user = admin
144
145 # default admin password, can be changed before first start of grafana,  or in profile settings
146 ;admin_password = admin
147
148 # used for signing
149 ;secret_key = SW2YcwTIb9zpOOhoPsMm
150
151 # Auto-login remember days
152 ;login_remember_days = 7
153 ;cookie_username = grafana_user
154 ;cookie_remember_name = grafana_remember
155
156 # disable gravatar profile images
157 ;disable_gravatar = false
158
159 # data source proxy whitelist (ip_or_domain:port separated by spaces)
160 ;data_source_proxy_whitelist =
161
162 [snapshots]
163 # snapshot sharing options
164 ;external_enabled = true
165 ;external_snapshot_url = https://snapshots-origin.raintank.io
166 ;external_snapshot_name = Publish to snapshot.raintank.io
167
168 # remove expired snapshot
169 ;snapshot_remove_expired = true
170
171 # remove snapshots after 90 days
172 ;snapshot_TTL_days = 90
173
174 #################################### Users ####################################
175 [users]
176 # disable user signup / registration
177 ;allow_sign_up = true
178
179 # Allow non admin users to create organizations
180 ;allow_org_create = true
181
182 # Set to true to automatically assign new users to the default organization (id 1)
183 ;auto_assign_org = true
184
185 # Default role new users will be automatically assigned (if disabled above is set to true)
186 ;auto_assign_org_role = Viewer
187
188 # Background text for the user field on the login page
189 ;login_hint = email or username
190
191 # Default UI theme ("dark" or "light")
192 ;default_theme = dark
193
194 [auth]
195 # Set to true to disable (hide) the login form, useful if you use OAuth, defaults to false
196 ;disable_login_form = false
197
198 # Set to true to disable the signout link in the side menu. useful if you use auth.proxy, defaults to false
199 ;disable_signout_menu = false
200
201 #################################### Anonymous Auth ##########################
202 [auth.anonymous]
203 # enable anonymous access
204 ;enabled = false
205
206 # specify organization name that should be used for unauthenticated users
207 ;org_name = Main Org.
208
209 # specify role for unauthenticated users
210 ;org_role = Viewer
211
212 #################################### Github Auth ##########################
213 [auth.github]
214 ;enabled = false
215 ;allow_sign_up = true
216 ;client_id = some_id
217 ;client_secret = some_secret
218 ;scopes = user:email,read:org
219 ;auth_url = https://github.com/login/oauth/authorize
220 ;token_url = https://github.com/login/oauth/access_token
221 ;api_url = https://api.github.com/user
222 ;team_ids =
223 ;allowed_organizations =
224
225 #################################### Google Auth ##########################
226 [auth.google]
227 ;enabled = false
228 ;allow_sign_up = true
229 ;client_id = some_client_id
230 ;client_secret = some_client_secret
231 ;scopes = https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email
232 ;auth_url = https://accounts.google.com/o/oauth2/auth
233 ;token_url = https://accounts.google.com/o/oauth2/token
234 ;api_url = https://www.googleapis.com/oauth2/v1/userinfo
235 ;allowed_domains =
236
237 #################################### Generic OAuth ##########################
238 [auth.generic_oauth]
239 ;enabled = false
240 ;name = OAuth
241 ;allow_sign_up = true
242 ;client_id = some_id
243 ;client_secret = some_secret
244 ;scopes = user:email,read:org
245 ;auth_url = https://foo.bar/login/oauth/authorize
246 ;token_url = https://foo.bar/login/oauth/access_token
247 ;api_url = https://foo.bar/user
248 ;team_ids =
249 ;allowed_organizations =
250
251 #################################### Grafana.com Auth ####################
252 [auth.grafana_com]
253 ;enabled = false
254 ;allow_sign_up = true
255 ;client_id = some_id
256 ;client_secret = some_secret
257 ;scopes = user:email
258 ;allowed_organizations =
259
260 #################################### Auth Proxy ##########################
261 [auth.proxy]
262 ;enabled = false
263 ;header_name = X-WEBAUTH-USER
264 ;header_property = username
265 ;auto_sign_up = true
266 ;ldap_sync_ttl = 60
267 ;whitelist = 192.168.1.1, 192.168.2.1
268
269 #################################### Basic Auth ##########################
270 [auth.basic]
271 ;enabled = true
272
273 #################################### Auth LDAP ##########################
274 [auth.ldap]
275 ;enabled = false
276 ;config_file = /etc/grafana/ldap.toml
277 ;allow_sign_up = true
278
279 #################################### SMTP / Emailing ##########################
280 [smtp]
281 ;enabled = false
282 ;host = localhost:25
283 ;user =
284 # If the password contains # or ; you have to wrap it with trippel quotes. Ex """#password;"""
285 ;password =
286 ;cert_file =
287 ;key_file =
288 ;skip_verify = false
289 ;from_address = admin@grafana.localhost
290 ;from_name = Grafana
291
292 [emails]
293 ;welcome_email_on_sign_up = false
294
295 #################################### Logging ##########################
296 [log]
297 # Either "console", "file", "syslog". Default is console and  file
298 # Use space to separate multiple modes, e.g. "console file"
299 ;mode = console file
300
301 # Either "debug", "info", "warn", "error", "critical", default is "info"
302 ;level = info
303
304 # optional settings to set different levels for specific loggers. Ex filters = sqlstore:debug
305 ;filters =
306
307
308 # For "console" mode only
309 [log.console]
310 ;level =
311
312 # log line format, valid options are text, console and json
313 ;format = console
314
315 # For "file" mode only
316 [log.file]
317 ;level =
318
319 # log line format, valid options are text, console and json
320 ;format = text
321
322 # This enables automated log rotate(switch of following options), default is true
323 ;log_rotate = true
324
325 # Max line number of single file, default is 1000000
326 ;max_lines = 1000000
327
328 # Max size shift of single file, default is 28 means 1 << 28, 256MB
329 ;max_size_shift = 28
330
331 # Segment log daily, default is true
332 ;daily_rotate = true
333
334 # Expired days of log file(delete after max days), default is 7
335 ;max_days = 7
336
337 [log.syslog]
338 ;level =
339
340 # log line format, valid options are text, console and json
341 ;format = text
342
343 # Syslog network type and address. This can be udp, tcp, or unix. If left blank, the default unix endpoints will be used.
344 ;network =
345 ;address =
346
347 # Syslog facility. user, daemon and local0 through local7 are valid.
348 ;facility =
349
350 # Syslog tag. By default, the process' argv[0] is used.
351 ;tag =
352
353
354 #################################### AMQP Event Publisher ##########################
355 [event_publisher]
356 ;enabled = false
357 ;rabbitmq_url = amqp://localhost/
358 ;exchange = grafana_events
359
360 #################################### Dashboard JSON files ##########################
361 [dashboards.json]
362 enabled = true
363 path = /var/lib/grafana/dashboards
364
365 #################################### Alerting ############################
366 [alerting]
367 # Disable alerting engine & UI features
368 ;enabled = true
369 # Makes it possible to turn off alert rule execution but alerting UI is visible
370 ;execute_alerts = true
371
372 #################################### Internal Grafana Metrics ##########################
373 # Metrics available at HTTP API Url /api/metrics
374 [metrics]
375 # Disable / Enable internal metrics
376 ;enabled           = true
377
378 # Publish interval
379 ;interval_seconds  = 10
380
381 # Send internal metrics to Graphite
382 [metrics.graphite]
383 # Enable by setting the address setting (ex localhost:2003)
384 ;address =
385 ;prefix = prod.grafana.%(instance_name)s.
386
387 #################################### Grafana.com integration  ##########################
388 # Url used to to import dashboards directly from Grafana.com
389 [grafana_com]
390 ;url = https://grafana.com
391
392 #################################### External image storage ##########################
393 [external_image_storage]
394 # Used for uploading images to public servers so they can be included in slack/email messages.
395 # you can choose between (s3, webdav)
396 ;provider =
397
398 [external_image_storage.s3]
399 ;bucket_url =
400 ;access_key =
401 ;secret_key =
402
403 [external_image_storage.webdav]
404 ;url =
405 ;public_url =
406 ;username =
407 ;password =