Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

rename to graviton savings dashboard #953

Merged
merged 2 commits into from
Sep 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion cid/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,12 @@ def load_catalog(self, catalog_url):
''' load additional resources from catalog
'''
try:
catalog = yaml.safe_load(self.get_page(catalog_url).text)
if 'https://' in catalog_url:
text = self.get_page(catalog_url).text
else:
with open(catalog_url, encoding='utf-8') as catalog_file:
text = catalog_file.read()
catalog = yaml.safe_load(text)
except (requests.exceptions.RequestException, yaml.error.MarkedYAMLError) as exc:
logger.warning(f'Failed to load a catalog url: {exc}')
logger.debug(exc, exc_info=True)
Expand Down
3 changes: 2 additions & 1 deletion dashboards/catalog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ Resources:
- Url: data-transfer/DataTransfer-Cost-Analysis-Dashboard.yaml
- Url: aws-marketplace/aws-marketplace-spg.yaml
- Url: extended-support-cost-projection/extended-support-cost-projection.yaml
- Url: graviton-opportunities-dashboard/graviton_dashboard.yaml
- Url: graviton-savings-dashboard/graviton_savings_dashboard.yaml
- Url: graviton-savings-dashboard/graviton_legacy.yaml # deprecated
- Url: health-events/health-events.yaml
- Url: scad-containers-cost-allocation/scad-containers-cost-allocation.yaml
- Url: aws-feeds/aws-feeds.yaml
Expand Down
14 changes: 14 additions & 0 deletions dashboards/graviton-savings-dashboard/graviton_legacy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
dashboards:
GRAVITON_DASHBOARD:
dependsOn:
datasets:
- graviton_ec2_view
- graviton_elasticache_view
- graviton_opensearch_view
- graviton_rds_view
name: Graviton Opportunities Dashboard
deprecationNotice: "This version is deprecated. Delete it and install 'graviton-savings' instead."
dashboardId: graviton-opportunities
category: Advanced
theme: MIDNIGHT
data: '{}'
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
dashboards:
GRAVITON_DASHBOARD:
GRAVITON_SAVINGS_DASHBOARD:
dependsOn:
datasets:
- graviton_ec2_view
- graviton_elasticache_view
- graviton_opensearch_view
- graviton_rds_view
name: Graviton Opportunities Dashboard
dashboardId: graviton-opportunities
name: Graviton Savings Dashboard
dashboardId: graviton-savings
category: Advanced
theme: MIDNIGHT
data: |-
Expand Down
Loading