Grafana Custom Configuration

Grafana Custom Configuration

Grafana Custom Configuration

WARNING: It is recommended to not change default configuration.

Configuration

You can pass custom configuration file to Grafana by setting grafana.config_files.custom.

Create a custom configuration file (grafana.ini) like the following.

instance_name = test_grafana

dcos security secrets create --file grafana.ini dcos-monitoring/grafana-ini

Create a custom option file (options.json) like the following.

{
  "grafana": {
    "config_files": {
      "custom": "dcos-monitoring/grafana-ini",
    }
  }
}

Read more about Grafana Configuration

LDAP

By default LDAP is disabled.

You can configure LDAP Authentication by setting grafana.config_files.ldap.

Create a custom configuration file (ldap.toml) like the following.

[[servers]]
host = "127.0.0.1"
port = 389
use_ssl = false
start_tls = false
ssl_skip_verify = false
bind_dn = "cn=admin,dc=grafana,dc=org"
bind_password = 'grafana'
search_filter = "(cn=%s)"
search_base_dns = ["dc=grafana,dc=org"]

[servers.attributes]
name = "givenName"
surname = "sn"
username = "cn"
member_of = "memberOf"
email =  "email"
dcos security secrets create --file ldap.toml dcos-monitoring/ldap

Create a custom option file (options.json) like the following.

{
  "grafana": {
    "config_files": {
      "ldap": "dcos-monitoring/ldap",
    }
  }
}

Read more about Grafana LDAP configuration