Skip to content

Commit

Permalink
fix: grafana dashboard templating
Browse files Browse the repository at this point in the history
Signed-off-by: Tarun Gupta Akirala <tarun.akirala@nutanix.com>
  • Loading branch information
takirala committed Jan 30, 2025
1 parent 6ec18e5 commit 3c8f06c
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 18 deletions.
22 changes: 11 additions & 11 deletions cost-analyzer/grafana-dashboards/attached-disks.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -112,7 +112,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum(container_fs_limit_bytes{instance=~'$disk', device!=\"tmpfs\", id=\"/\", cluster_id=~'$cluster'}) by (cluster_id, instance)",
Expand All @@ -130,7 +130,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -213,7 +213,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum(container_fs_usage_bytes{instance=~'$disk',id=\"/\", cluster_id=~'$cluster'}) by (cluster_id, instance) / sum(container_fs_limit_bytes{instance=~'$disk',device!=\"tmpfs\", id=\"/\", cluster_id=~'$cluster'}) by (cluster_id,instance)",
Expand All @@ -231,7 +231,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -314,7 +314,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "1 - sum(container_fs_inodes_free{instance=~'$disk',id=\"/\", cluster_id=~'$cluster'}) by (cluster_id, instance) / sum(container_fs_inodes_total{instance=~'$disk',id=\"/\", cluster_id=~'$cluster'}) by (cluster_id, instance)",
Expand All @@ -331,7 +331,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -412,7 +412,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "sum(container_fs_usage_bytes{instance=~'$disk',id=\"/\", cluster_id=~'$cluster'}) by (cluster_id, instance)",
Expand Down Expand Up @@ -441,7 +441,7 @@
"current": {
"selected": false,
"text": "Prometheus",
"value": "PBFA97CFB590B2093"
"value": "Prometheus"
},
"hide": 0,
"includeAll": false,
Expand All @@ -463,7 +463,7 @@
},
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"definition": "label_values(cluster_id)",
"hide": 0,
Expand All @@ -489,7 +489,7 @@
},
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"definition": "label_values(container_fs_limit_bytes{cluster_id=~\"$cluster\"}, instance)",
"hide": 0,
Expand Down
4 changes: 2 additions & 2 deletions cost-analyzer/grafana-dashboards/network-cloud-services.json
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@
"current": {
"selected": false,
"text": "Prometheus",
"value": "PBFA97CFB590B2093"
"value": "Prometheus"
},
"hide": 0,
"includeAll": false,
Expand Down Expand Up @@ -351,7 +351,7 @@
},
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"definition": "label_values(kube_pod_container_status_running{namespace=\"$namespace\"},container)",
"hide": 0,
Expand Down
2 changes: 1 addition & 1 deletion cost-analyzer/grafana-dashboards/networkCosts-metrics.json
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@
"current": {
"selected": false,
"text": "Prometheus",
"value": "PBFA97CFB590B2093"
"value": "Prometheus"
},
"hide": 0,
"includeAll": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -865,7 +865,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "kubecost_read_db_size",
Expand Down Expand Up @@ -905,7 +905,7 @@
"current": {
"selected": false,
"text": "Prometheus",
"value": "PBFA97CFB590B2093"
"value": "Prometheus"
},
"hide": 0,
"includeAll": false,
Expand Down
4 changes: 2 additions & 2 deletions cost-analyzer/grafana-dashboards/workload-metrics.json
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,7 @@
"current": {
"selected": false,
"text": "Prometheus",
"value": "PBFA97CFB590B2093"
"value": "Prometheus"
},
"hide": 0,
"includeAll": false,
Expand Down Expand Up @@ -859,7 +859,7 @@
},
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
"uid": "${datasource}"
},
"definition": "label_values({namespace=~\"$namespace\", pod=~\"$pod\"},container)",
"hide": 0,
Expand Down

0 comments on commit 3c8f06c

Please sign in to comment.