logo
Menu

Detect and remediate cost waste | S02 E29 | Build On Weekly

This week, Rohini and Darko are joined by Steph, as we look at a way to detect potential unwanted costs and remediate them.We did this using AWS Config and some AWS Systems Manager magic

AWS Admin
Amazon Employee
Published Sep 21, 2023
Last Modified Jun 25, 2024
Screenshot of the AWS Config Dashboard showing non-compliant resources
This is what success looks like
It is very important to be aware of your costs when running workloads in the cloud. Do you know if you have any lingering resources (unused Elastic IPs, detached EBS volumes) that are causing you unwanted cots? 🤔 Well, today we have Steph joining us and demonstrating how we can fix all this using AWS Config and AWS Systems Manager Automation.
We ended up not being able to fix it on stream, BUT, Darko did spend some time and made it work at the end. And here is how it works now:

The fix

Alright, the issue we had is that we were not able to pass the SSM Automation document the correct parameters and execute the automation. After some time spent searching online and looking at other options in the SSM Automation documentation, we've realized that the solution is to use a different action type.
Instead of using aws:executeAwsApi, the better option was just to use aws:createTags, as that is what we actually wanted! 🥳 This simple change has made it possible to create a new automation document that has the following contents:
Then - to pass it the Tags parameter we use the following format: {"Key":"COST_ALERT","Value":"UnusedEip"}. Huzzah!
If you wish to see this in action, check out the addendum video here:
Check out the full stream recording here:
Loading...

Links from today's episode

Reach out to the hosts and guests:

Any opinions in this post are those of the individual author and may not reflect the opinions of AWS.

Comments