|
|
|
|
|
by solidasparagus
2142 days ago
|
|
Very helpful. Pretty hard to do comprehensively without (but less comprehensive solutions could still be useful). The biggest question is "where are you going to get your data about current spend?. AFAIK the budget data lags behind usage (which is what I assume is the reason people haven't done this before). You can do this at a per-service level (e.g. EC2) by periodically polling EC2 for active resources and keeping a running tally of cost by yourself. This works well for some services like EC2, RDS (although serverless Aurora gets tricky), etc. However for other managed services like S3 or Lambda, it's harder to keep track of how much you have spent. Cloudtrail could be useful here, but it probably doesn't have enough information to calculate actual cost (e.g. Lambda charging based on invocation time or Athena charging based on the volume of data scanned). But even something as simple as a tool that keeps track of just your EC2 instance spend and shuts them down if it gets too high would be useful to developers who have AWS accounts for their side projects. |
|
> The biggest question is "where are you going to get your data about current spend?. AFAIK the budget data lags behind usage
interesting, I was thinking I could poll billing metrics (total charges etc) to figure out account level charges.
In your experience, do you care more about EC2 costs or that was just an example?