Skip to content

Commit 0655011

Browse files
committed
Add another host and docker monitoring dashboard
1 parent d051358 commit 0655011

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

grafana/provision.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,14 @@ case "${CLIENT}" in
249249
url="https://grafana.com/api/dashboards/${id}/revisions/${revision}/download"
250250
file='/etc/grafana/provisioning/dashboards/docker-host-container-overview.json'
251251
wget -t 3 -T 10 -qcO - "${url}" | jq 'walk(if . == "${DS_PROMETHEUS}" then "Prometheus" else . end)' >"${file}"
252+
# Another cadvisor and node exporter dashboard
253+
id=15120
254+
revision=$(wget -t 3 -T 10 -qO - https://grafana.com/api/dashboards/${id} | jq .revision)
255+
url="https://grafana.com/api/dashboards/${id}/revisions/${revision}/download"
256+
file='/etc/grafana/provisioning/dashboards/host-docker-monitoring.json'
257+
wget -t 3 -T 10 -qcO - "${url}" | jq '.title = "Host & Docker Monitoring"' \
258+
| jq '.panels |= map(if .title == "Temp" then .targets[0] |= (.legendFormat = "{{type}}" | .expr = "node_thermal_zone_temp")| .options.orientation = "vertical" elif .title == "Temperature" then .targets[0].expr = "node_thermal_zone_temp" else . end)' \
259+
| jq 'walk(if . == "${DS_PROMETHEUS}" then "Prometheus" else . end)' >"${file}"
252260
# Log file dashboard (via loki)
253261
id=20223
254262
revision=$(wget -t 3 -T 10 -qO - https://grafana.com/api/dashboards/${id} | jq .revision)

0 commit comments

Comments
 (0)