mirror of https://github.com/istio/istio.io.git
[master] Fix grafana script (#8817)
* Fix grafana script Fixes https://github.com/istio/istio/issues/30173 * Update index.md Co-authored-by: John Howard <howardjohn@google.com>
This commit is contained in:
parent
0e98207a6f
commit
a4121fd3c1
|
@ -45,10 +45,10 @@ $ GRAFANA_CRED="USER:PASSWORD"
|
|||
$ # The name of the Prometheus data source to use
|
||||
$ GRAFANA_DATASOURCE="Prometheus"
|
||||
$ # The version of Istio to deploy
|
||||
$ VERSION={{< istio_version >}}
|
||||
$ VERSION={{< istio_full_version >}}
|
||||
$ # Import all Istio dashboards
|
||||
$ for DASHBOARD in 7639 11829 7636 7630 7642 7645; do
|
||||
$ REVISION="$(curl -s https://grafana.com/api/dashboards/${DASHBOARD}/revisions -s | jq ".items[] | select(.description | contains(\"${VERSION}$ \")) | .revision")"
|
||||
$ REVISION="$(curl -s https://grafana.com/api/dashboards/${DASHBOARD}/revisions -s | jq ".items[] | select(.description | contains(\"${VERSION}$\")) | .revision")"
|
||||
$ curl -s https://grafana.com/api/dashboards/${DASHBOARD}/revisions/${REVISION}/download > /tmp/dashboard.json
|
||||
$ echo "Importing $(cat /tmp/dashboard.json | jq -r '.title') (revision ${REVISION}, id ${DASHBOARD})..."
|
||||
$ curl -s -k -u "$GRAFANA_CRED" -XPOST \
|
||||
|
|
Loading…
Reference in New Issue