Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Converting a Grafana JSON dashboard to YAML doesn't add datasource to the yaml #238

Open
mib93 opened this issue Jul 28, 2024 · 0 comments

Comments

@mib93
Copy link

mib93 commented Jul 28, 2024

Hi, if I convert my Grafana dashboard.json to dashboard.yaml using the guide at ‘https://github.com/K-Phoen/dark/blob/master/docs/usage/converting-grafana-json-to-yaml.md’, it doesn’t add the datasource to the YAML file.
For example:
dashboard.json
....
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "PCB1AD8455F96C165"
}
.....

this datasource is not added in dashboard.yaml
....
- name: DNS Controller
panels:
- stat:
title: Last Successful Sync with the DNS provider (per Pod)
description: Test
span: 3
targets:
- prometheus:
query: "external_dns_controller_last_sync_timestamp_seconds * 1000"
legend: '{{{{pod}}}}'
ref: A
interval_factor: 0
unit: dateTimeAsLocal
orientation: horizontal
text: value_and_name
value_type: last_non_null
color_mode: value
title_font_size: 15
value_font_size: 25
threshold_mode: absolute
thresholds:
- color: green
...

Best Regards

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant