sample.ini 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263
  1. ##################### Grafana Configuration Example #####################
  2. #
  3. # Everything has defaults so you only need to uncomment things you want to
  4. # change
  5. # possible values : production, development
  6. ; app_mode = production
  7. #################################### Paths ####################################
  8. [paths]
  9. # Path to where grafana can store temp files, sessions, and the sqlite3 db (if that is used)
  10. #
  11. ;data = /var/lib/grafana
  12. #
  13. # Directory where grafana can store logs
  14. #
  15. ;logs = /var/log/grafana
  16. #
  17. # Directory where grafana will automatically scan and look for plugins
  18. #
  19. ;plugins = /var/lib/grafana/plugins
  20. #
  21. #################################### Server ####################################
  22. [server]
  23. # Protocol (http or https)
  24. ;protocol = http
  25. # The ip address to bind to, empty will bind to all interfaces
  26. ;http_addr =
  27. # The http port to use
  28. ;http_port = 3000
  29. # The public facing domain name used to access grafana from a browser
  30. ;domain = localhost
  31. # Redirect to correct domain if host header does not match domain
  32. # Prevents DNS rebinding attacks
  33. ;enforce_domain = false
  34. # The full public facing url
  35. ;root_url = %(protocol)s://%(domain)s:%(http_port)s/
  36. # Log web requests
  37. ;router_logging = false
  38. # the path relative working path
  39. ;static_root_path = public
  40. # enable gzip
  41. ;enable_gzip = false
  42. # https certs & key file
  43. ;cert_file =
  44. ;cert_key =
  45. #################################### Database ####################################
  46. [database]
  47. # Either "mysql", "postgres" or "sqlite3", it's your choice
  48. ;type = sqlite3
  49. ;host = 127.0.0.1:3306
  50. ;name = grafana
  51. ;user = root
  52. ;password =
  53. # For "postgres" only, either "disable", "require" or "verify-full"
  54. ;ssl_mode = disable
  55. # For "sqlite3" only, path relative to data_path setting
  56. ;path = grafana.db
  57. #################################### Session ####################################
  58. [session]
  59. # Either "memory", "file", "redis", "mysql", "postgres", default is "file"
  60. ;provider = file
  61. # Provider config options
  62. # memory: not have any config yet
  63. # file: session dir path, is relative to grafana data_path
  64. # redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=grafana`
  65. # mysql: go-sql-driver/mysql dsn config string, e.g. `user:password@tcp(127.0.0.1:3306)/database_name`
  66. # postgres: user=a password=b host=localhost port=5432 dbname=c sslmode=disable
  67. ;provider_config = sessions
  68. # Session cookie name
  69. ;cookie_name = grafana_sess
  70. # If you use session in https only, default is false
  71. ;cookie_secure = false
  72. # Session life time, default is 86400
  73. ;session_life_time = 86400
  74. #################################### Analytics ####################################
  75. [analytics]
  76. # Server reporting, sends usage counters to stats.grafana.org every 24 hours.
  77. # No ip addresses are being tracked, only simple counters to track
  78. # running instances, dashboard and error counts. It is very helpful to us.
  79. # Change this option to false to disable reporting.
  80. ;reporting_enabled = true
  81. # Google Analytics universal tracking code, only enabled if you specify an id here
  82. ;google_analytics_ua_id =
  83. #################################### Security ####################################
  84. [security]
  85. # default admin user, created on startup
  86. ;admin_user = admin
  87. # default admin password, can be changed before first start of grafana, or in profile settings
  88. ;admin_password = admin
  89. # used for signing
  90. ;secret_key = SW2YcwTIb9zpOOhoPsMm
  91. # Auto-login remember days
  92. ;login_remember_days = 7
  93. ;cookie_username = grafana_user
  94. ;cookie_remember_name = grafana_remember
  95. # disable gravatar profile images
  96. ;disable_gravatar = false
  97. # data source proxy whitelist (ip_or_domain:port seperated by spaces)
  98. ;data_source_proxy_whitelist =
  99. [snapshots]
  100. # snapshot sharing options
  101. ;external_enabled = true
  102. ;external_snapshot_url = https://snapshots-origin.raintank.io
  103. ;external_snapshot_name = Publish to snapshot.raintank.io
  104. #################################### Users ####################################
  105. [users]
  106. # disable user signup / registration
  107. ;allow_sign_up = true
  108. # Allow non admin users to create organizations
  109. ;allow_org_create = true
  110. # Set to true to automatically assign new users to the default organization (id 1)
  111. ;auto_assign_org = true
  112. # Default role new users will be automatically assigned (if disabled above is set to true)
  113. ;auto_assign_org_role = Viewer
  114. # Background text for the user field on the login page
  115. ;login_hint = email or username
  116. #################################### Anonymous Auth ##########################
  117. [auth.anonymous]
  118. # enable anonymous access
  119. ;enabled = false
  120. # specify organization name that should be used for unauthenticated users
  121. ;org_name = Main Org.
  122. # specify role for unauthenticated users
  123. ;org_role = Viewer
  124. #################################### Github Auth ##########################
  125. [auth.github]
  126. ;enabled = false
  127. ;allow_sign_up = false
  128. ;client_id = some_id
  129. ;client_secret = some_secret
  130. ;scopes = user:email,read:org
  131. ;auth_url = https://github.com/login/oauth/authorize
  132. ;token_url = https://github.com/login/oauth/access_token
  133. ;api_url = https://api.github.com/user
  134. ;team_ids =
  135. ;allowed_organizations =
  136. #################################### Google Auth ##########################
  137. [auth.google]
  138. ;enabled = false
  139. ;allow_sign_up = false
  140. ;client_id = some_client_id
  141. ;client_secret = some_client_secret
  142. ;scopes = https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email
  143. ;auth_url = https://accounts.google.com/o/oauth2/auth
  144. ;token_url = https://accounts.google.com/o/oauth2/token
  145. ;api_url = https://www.googleapis.com/oauth2/v1/userinfo
  146. ;allowed_domains =
  147. #################################### Auth Proxy ##########################
  148. [auth.proxy]
  149. ;enabled = false
  150. ;header_name = X-WEBAUTH-USER
  151. ;header_property = username
  152. ;auto_sign_up = true
  153. #################################### Basic Auth ##########################
  154. [auth.basic]
  155. ;enabled = true
  156. #################################### Auth LDAP ##########################
  157. [auth.ldap]
  158. ;enabled = false
  159. ;config_file = /etc/grafana/ldap.toml
  160. #################################### SMTP / Emailing ##########################
  161. [smtp]
  162. ;enabled = false
  163. ;host = localhost:25
  164. ;user =
  165. ;password =
  166. ;cert_file =
  167. ;key_file =
  168. ;skip_verify = false
  169. ;from_address = admin@grafana.localhost
  170. [emails]
  171. ;welcome_email_on_sign_up = false
  172. #################################### Logging ##########################
  173. [log]
  174. # Either "console", "file", default is "console"
  175. # Use comma to separate multiple modes, e.g. "console, file"
  176. ;mode = console, file
  177. # Buffer length of channel, keep it as it is if you don't know what it is.
  178. ;buffer_len = 10000
  179. # Either "Trace", "Debug", "Info", "Warn", "Error", "Critical", default is "Trace"
  180. ;level = Info
  181. # For "console" mode only
  182. [log.console]
  183. ;level =
  184. # For "file" mode only
  185. [log.file]
  186. ;level =
  187. # This enables automated log rotate(switch of following options), default is true
  188. ;log_rotate = true
  189. # Max line number of single file, default is 1000000
  190. ;max_lines = 1000000
  191. # Max size shift of single file, default is 28 means 1 << 28, 256MB
  192. ;max_lines_shift = 28
  193. # Segment log daily, default is true
  194. ;daily_rotate = true
  195. # Expired days of log file(delete after max days), default is 7
  196. ;max_days = 7
  197. #################################### AMPQ Event Publisher ##########################
  198. [event_publisher]
  199. ;enabled = false
  200. ;rabbitmq_url = amqp://localhost/
  201. ;exchange = grafana_events
  202. ;#################################### Dashboard JSON files ##########################
  203. [dashboards.json]
  204. ;enabled = false
  205. ;path = /var/lib/grafana/dashboards