mapbox/ecs-conex

Alarming on ECR registry size

Opened this issue · 3 comments

Moving this comment on PR #63 into its own issue:

When I investigated a few days ago, there din't seem to be a way to alarm on ECR. Curious if we have creative ways to use CustomMetrics at our disposal to setup ECR registry size.

cc @rclark @yhahn @emilymcafee

I think this would involve a scheduled lambda function that just counts images in the ECR repos. It could either put a custom metric and a correlated alarm fires when the metric is above a threshold, or the lambda function could directly trip an alarm when it detects too many images.

I'm sprinting next week on internal tools, but happy to jump on this afterwards if no one's grabbed it.

Changing course on this. Instead of alarming on registry size, I'm experimenting with adding automatic cleanup when an image is created and uploaded to the registry 👉 #97