Skip to content

Commit b9f2087

Browse files
committed
Dashboard EC2 update
1 parent 4c0139d commit b9f2087

File tree

3 files changed

+2354
-2122
lines changed

3 files changed

+2354
-2122
lines changed

.github/workflows/standards.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
"aws-cognito/aws-cognito.json",
1515
"aws-direct-connect/aws-direct-connect.json",
1616
"aws-dynamodb/aws-dynamodb.json",
17-
"aws-ebs/aws-ebs.json"
17+
"aws-ebs/aws-ebs.json",
18+
"aws-ec2/aws-ec2.json"
1819
]
1920

2021
standard_footer = "<a target=\"_blank\" href=\"http://www.monitoringartist.com\" title=\"Dashboard maintained by Monitoring Artist - DevOps / Docker / Kubernetes / AWS ECS / Google GCP / Zabbix / Zenoss / Terraform / Monitoring\"><img src=\"https://monitoringartist.github.io/monitoring-artist-logo-grafana.png\" height=\"30px\" /></a> | \n<a target=\"_blank\" href=\"https://docs.aws.amazon.com/transfer/latest/userguide/monitoring.html\">AWS CloudWatch Transfer Family documentation</a> | \n<a target=\"_blank\" href=\"https://grafana.com/dashboards/20008\">Installed from Grafana.com dashboards</a>"
@@ -34,8 +35,10 @@ def validate_panel(f, panel):
3435
for target in panel["targets"]:
3536
if "datasource" in target and "uid" in target["datasource"] and target["datasource"]["uid"] != "$datasource":
3637
print('Dashboard ' + f + ' - panel: ' + panel['title'] + ' doesn\'t use $datasource variable')
37-
if "fieldConfig" in panel and "custom" in panel["fieldConfig"] and "lineWidth" in panel["fieldConfig"]["custom"] and panel["fieldConfig"]["custom"] ["lineWidth"] != 1:
38+
if "fieldConfig" in panel and "defaults" in panel["fieldConfig"] and "custom" in panel["fieldConfig"]["defaults"] and "lineWidth" in panel["fieldConfig"]["defaults"]["custom"] and panel["fieldConfig"]["defaults"]["custom"] ["lineWidth"] != 1:
3839
print('Dashboard ' + f + ' - panel: ' + panel['title'] + ' doesn\'t use lineWidth = 1')
40+
if "options" in panel and "legend" in panel["options"] and "calcs" in panel["options"]["legend"] and "lastNotNull" in panel["options"]["legend"]["calcs"]:
41+
print('Dashboard ' + f + ' - panel: ' + panel['title'] + ' has lastNotNull in the legend')
3942

4043
def validate_config(f, dashboard):
4144
if 'panels' in dashboard:

0 commit comments

Comments
 (0)