Skip to content

Commit

Permalink
stash
Browse files Browse the repository at this point in the history
  • Loading branch information
consideRatio committed Oct 22, 2024
1 parent 5b47aed commit 5ec33ea
Showing 1 changed file with 30 additions and 15 deletions.
45 changes: 30 additions & 15 deletions grafana-dashboards/cloud-cost-aws.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,27 @@ local var = grafonnet.dashboard.variable;
local common = import "./common.libsonnet";


local totalDailyCosts =
local dailyCosts =
common.tsOptions
+ ts.new("Total daily costs")
+ ts.new("Daily costs")
+ ts.panelOptions.withDescription(
|||
Total daily costs
"Costs account" refers to the associated AWS account's costs, and "Costs
attributable" refers to the costs that has successfully been attributed to
2i2c managed cloud infrastructure.
There are some costs associated with 2i2c managed cloud infrastructure
that can't be attributed to it, but they are expected to be small. As an
example, this panel is presenting data that incurred a small cost to ask
for, and that cost is an example of what we fail to attribute and is only
captured in the AWS account's cost.
---
**Note**
- All costs are [unblended costs](https://aws.amazon.com/blogs/aws-cloud-financial-management/understanding-your-aws-cost-datasets-a-cheat-sheet/)
- All costs are tied to usage and isn't a sum of usage and credits etc.
|||
)
+ ts.queryOptions.withTargets([
Expand All @@ -23,12 +38,12 @@ local totalDailyCosts =
]);


local totalDailyCostsPerHub =
local dailyCostsPerHub =
common.tsOptions
+ ts.new("Total daily costs per hub")
+ ts.new("Daily costs per hub")
+ ts.panelOptions.withDescription(
|||
Total daily costs per hub
Daily costs per hub
|||
)
+ ts.queryOptions.withTargets([
Expand All @@ -39,12 +54,12 @@ local totalDailyCostsPerHub =
]);


local totalDailyCostsPerComponent =
local dailyCostsPerComponent =
common.tsOptions
+ ts.new("Total daily costs per component")
+ ts.panelOptions.withDescription(
|||
Total daily costs per component
Daily costs per component
|||
)
+ ts.queryOptions.withTargets([
Expand All @@ -55,12 +70,12 @@ local totalDailyCostsPerComponent =
]);


local totalDailyCostsPerComponentAndHub =
local dailyCostsPerComponentAndHub =
common.tsOptions
+ ts.new("Total daily costs per component, for ${hub}")
+ ts.new("Daily costs per component, for ${hub}")
+ ts.panelOptions.withDescription(
|||
Total daily costs per component, for ${hub}
Daily costs per component, for ${hub}
|||
)
+ ts.panelOptions.withRepeat("hub")
Expand Down Expand Up @@ -91,10 +106,10 @@ dashboard.new("Cloud cost attribution")
+ dashboard.withPanels(
grafonnet.util.grid.makeGrid(
[
totalDailyCosts,
totalDailyCostsPerHub,
totalDailyCostsPerComponent,
totalDailyCostsPerComponentAndHub
dailyCosts,
dailyCostsPerHub,
dailyCostsPerComponent,
dailyCostsPerComponentAndHub
],
panelWidth=24,
panelHeight=12,
Expand Down

0 comments on commit 5ec33ea

Please sign in to comment.