You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I noticed that the code is doing some cool stuff to import dashboards via the http interface:
for file in *-dashboard.json ; do
if [ -e "$file" ] ; then
# wrap exported Grafana dashboard into valid json
echo "importing $file" &&
(echo '{"dashboard":';cat "$file";echo ',"inputs":[{"name":"DS_PROMETHEUS","pluginId":"prometheus","type":"datasource","value":"prometheus"}]}') | curl --silent --fail --show-error \
--request POST http://localhost:3000/api/dashboards/import \
--header "Content-Type: application/json" \
--data-binary @-;
echo "" ;
fi
done ;
This seems to be an undocumented api, at least I can't find it on the grafana website. Where can I find more about this api? I've enabled persistent storage and I don't want to import the dashboards every time I bounce the container.
Thanks!
The text was updated successfully, but these errors were encountered:
Hi,
I noticed that the code is doing some cool stuff to import dashboards via the http interface:
This seems to be an undocumented api, at least I can't find it on the grafana website. Where can I find more about this api? I've enabled persistent storage and I don't want to import the dashboards every time I bounce the container.
Thanks!
The text was updated successfully, but these errors were encountered: