Skip to content

Commit 1c0a188

Browse files
committed
Merge remote-tracking branch 'upstream/master' into postgres-query-builder
2 parents 24eafa4 + 9413ce5 commit 1c0a188

File tree

39 files changed

+653
-127
lines changed

39 files changed

+653
-127
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@
2828
* **AuthProxy**: Support IPv6 in Auth proxy white list [#11330](https://github.com/grafana/grafana/pull/11330), thx [@corny](https://github.com/corny)
2929
* **SMTP**: Don't connect to STMP server using TLS unless configured. [#7189](https://github.com/grafana/grafana/issues/7189)
3030
* **Prometheus**: Escape backslash in labels correctly. [#10555](https://github.com/grafana/grafana/issues/10555), thx [@roidelapluie](https://github.com/roidelapluie)
31-
* **Variables** Case-insensitive sorting for template values [#11128](https://github.com/grafana/grafana/issues/11128) thx [@cross](https://github.com/cross)
31+
* **Variables**: Case-insensitive sorting for template values [#11128](https://github.com/grafana/grafana/issues/11128) thx [@cross](https://github.com/cross)
32+
* **Annotations (native)**: Change default limit from 10 to 100 when querying api [#11569](https://github.com/grafana/grafana/issues/11569), thx [@flopp999](https://github.com/flopp999)
3233

3334
# 5.0.4 (2018-03-28)
3435

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ clone_folder: c:\gopath\src\github.com\grafana\grafana
77
environment:
88
nodejs_version: "6"
99
GOPATH: c:\gopath
10-
GOVERSION: 1.9.2
10+
GOVERSION: 1.10
1111

1212
install:
1313
- rmdir c:\go /s /q

docs/sources/administration/provisioning.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ datasources:
138138
```
139139
140140
#### Custom Settings per Datasource
141+
Please refer to each datasource documentation for specific provisioning examples.
141142
142143
| Datasource | Misc |
143144
| ---- | ---- |

docs/sources/features/datasources/cloudwatch.md

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,40 @@ server is running on AWS you can use IAM Roles and authentication will be handle
4343

4444
Checkout AWS docs on [IAM Roles](http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html)
4545

46+
## IAM Policies
47+
48+
Grafana needs permissions granted via IAM to be able to read CloudWatch metrics
49+
and EC2 tags/instances. You can attach these permissions to IAM roles and
50+
utilize Grafana's built-in support for assuming roles.
51+
52+
Here is a minimal policy example:
53+
54+
```json
55+
{
56+
"Version": "2012-10-17",
57+
"Statement": [
58+
{
59+
"Sid": "AllowReadingMetricsFromCloudWatch",
60+
"Effect": "Allow",
61+
"Action": [
62+
"cloudwatch:ListMetrics",
63+
"cloudwatch:GetMetricStatistics"
64+
],
65+
"Resource": "*"
66+
},
67+
{
68+
"Sid": "AllowReadingTagsFromEC2",
69+
"Effect": "Allow",
70+
"Action": [
71+
"ec2:DescribeTags",
72+
"ec2:DescribeInstances"
73+
],
74+
"Resource": "*"
75+
}
76+
]
77+
}
78+
```
79+
4680
### AWS credentials file
4781

4882
Create a file at `~/.aws/credentials`. That is the `HOME` path for user running grafana-server.
@@ -173,3 +207,37 @@ Amazon provides 1 million CloudWatch API requests each month at no additional ch
173207
it costs $0.01 per 1,000 GetMetricStatistics or ListMetrics requests. For each query Grafana will
174208
issue a GetMetricStatistics request and every time you pick a dimension in the query editor
175209
Grafana will issue a ListMetrics request.
210+
211+
## Configure datasource with provisioning
212+
213+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
214+
215+
Here are some provisioning examples for this datasource.
216+
217+
Using a credentials file
218+
```yaml
219+
apiVersion: 1
220+
221+
datasources:
222+
- name: Cloudwatch
223+
type: cloudwatch
224+
jsonData:
225+
authType: credentials
226+
defaultRegion: eu-west-2
227+
```
228+
229+
Using `accessKey` and `secretKey`
230+
231+
```yaml
232+
apiVersion: 1
233+
234+
datasources:
235+
- name: Cloudwatch
236+
type: cloudwatch
237+
jsonData:
238+
authType: keys
239+
defaultRegion: eu-west-2
240+
secureJsonData:
241+
accessKey: "<your access key>"
242+
secretKey: "<your secret key>"
243+
```

docs/sources/features/datasources/elasticsearch.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,3 +137,23 @@ Query | You can leave the search query blank or specify a lucene query
137137
Time | The name of the time field, needs to be date field.
138138
Text | Event description field.
139139
Tags | Optional field name to use for event tags (can be an array or a CSV string).
140+
141+
## Configure datasource with provisioning
142+
143+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
144+
145+
Here are some provisioning examples for this datasource.
146+
147+
```yaml
148+
apiVersion: 1
149+
150+
datasources:
151+
- name: Elastic
152+
type: elasticsearch
153+
access: proxy
154+
database: "[metrics-]YYYY.MM.DD"
155+
url: http://localhost:9200
156+
jsonData:
157+
interval: Daily
158+
timeField: "@timestamp"
159+
```

docs/sources/features/datasources/graphite.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,3 +120,21 @@ queries via the Dashboard menu / Annotations view.
120120

121121
Graphite supports two ways to query annotations. A regular metric query, for this you use the `Graphite query` textbox. A Graphite events query, use the `Graphite event tags` textbox,
122122
specify a tag or wildcard (leave empty should also work)
123+
124+
## Configure datasource with provisioning
125+
126+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
127+
128+
Here are some provisioning examples for this datasource.
129+
130+
```yaml
131+
apiVersion: 1
132+
133+
datasources:
134+
- name: Graphite
135+
type: graphite
136+
access: proxy
137+
url: http://localhost:8080
138+
jsonData:
139+
graphiteVersion: "1.1"
140+
```

docs/sources/features/datasources/influxdb.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,3 +174,22 @@ SELECT title, description from events WHERE $timeFilter order asc
174174
For InfluxDB you need to enter a query like in the above example. You need to have the ```where $timeFilter```
175175
part. If you only select one column you will not need to enter anything in the column mapping fields. The
176176
Tags field can be a comma separated string.
177+
178+
## Configure datasource with provisioning
179+
180+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
181+
182+
Here are some provisioning examples for this datasource.
183+
184+
```yaml
185+
apiVersion: 1
186+
187+
datasources:
188+
- name: InfluxDB
189+
type: influxdb
190+
access: proxy
191+
database: site
192+
user: grafana
193+
password: grafana
194+
url: http://localhost:8086
195+
```

docs/sources/features/datasources/mysql.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,3 +225,21 @@ tags | Optional field name to use for event tags as a comma separated string.
225225
## Alerting
226226

227227
Time series queries should work in alerting conditions. Table formatted queries is not yet supported in alert rule conditions.
228+
229+
## Configure datasource with provisioning
230+
231+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
232+
233+
Here are some provisioning examples for this datasource.
234+
235+
```yaml
236+
apiVersion: 1
237+
238+
datasources:
239+
- name: MySQL
240+
type: mysql
241+
url: localhost:3306
242+
database: grafana
243+
user: grafana
244+
password: password
245+
```

docs/sources/features/datasources/opentsdb.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,3 +88,22 @@ Query | Description
8888
*tag_values(cpu, hostanme, env=$env, region=$region)* | Return tag values for cpu metric, selected env tag value, selected region tag value and tag key hostname
8989

9090
For details on OpenTSDB metric queries checkout the official [OpenTSDB documentation](http://opentsdb.net/docs/build/html/index.html)
91+
92+
## Configure datasource with provisioning
93+
94+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
95+
96+
Here are some provisioning examples for this datasource.
97+
98+
```yaml
99+
apiVersion: 1
100+
101+
datasources:
102+
- name: OpenTsdb
103+
type: opentsdb
104+
access: proxy
105+
url: http://localhost:4242
106+
jsonData:
107+
tsdbResolution: 1
108+
tsdbVersion: 1
109+
```

docs/sources/features/datasources/postgres.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,3 +217,25 @@ tags | Optional field name to use for event tags as a comma separated string.
217217

218218
Time series queries should work in alerting conditions. Table formatted queries is not yet supported in alert rule
219219
conditions.
220+
221+
## Configure datasource with provisioning
222+
223+
It's now possible to configure datasources using config files with Grafanas provisioning system. You can read more about how it works and all the settings you can set for datasources on the [provisioning docs page](/administration/provisioning/#datasources)
224+
225+
Here are some provisioning examples for this datasource.
226+
227+
```yaml
228+
apiVersion: 1
229+
230+
datasources:
231+
- name: Postgres
232+
type: postgres
233+
url: localhost:5432
234+
database: grafana
235+
user: grafana
236+
secureJsonData:
237+
password: "Password!"
238+
jsonData:
239+
sslmode: "disable" # disable/require/verify-ca/verify-full
240+
241+
```

0 commit comments

Comments
 (0)