We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c14db6d commit d71861fCopy full SHA for d71861f
1 file changed
scripts/generate_datapoints.bash
@@ -0,0 +1,21 @@
1
+#!/usr/local/env bash
2
+
3
+set -xe
4
5
+CRYOSTAT_URL="$1"
6
7
+if [ -z $CRYOSTAT_URL ]; then
8
+ echo "Cryostat URL is expected as an argument. Found none"; exit 2
9
+fi
10
11
+# Get datasource UID
12
13
+DATASOURCE_UID=$(curl -kLs ${CRYOSTAT_URL}/grafana/api/datasources/name/jfr-datasource | jq .uid)
14
15
+echo $DATASOURCE_UID
16
17
18
+BODY="$(curl -ksL https://localhost:8080/grafana/api/dashboards/uid/main | jq .dashboard.panels[0].targets[0].url_options.data | sed -e 's/${__timeTo:date}/2024-08-28T20:23:35.127Z/' -e 's/${__timeFrom:date}/2024-05-01T20:23:35.127Z/')"
19
20
21
+curl -kL --data $BODY ${CRYOSTAT_URL}/grafana/api/datasources/proxy/uid/$DATASOURCE_UID
0 commit comments