[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/01: cdn: Update billing alarms.
From: |
Chris Marusich |
Subject: |
01/01: cdn: Update billing alarms. |
Date: |
Tue, 9 Jul 2019 02:56:18 -0400 (EDT) |
marusich pushed a commit to branch master
in repository maintenance.
commit bf5bbce7ed210d3518d0ff67687be010bbea3ec1
Author: Chris Marusich <address@hidden>
Date: Sun Jul 7 15:28:49 2019 -0700
cdn: Update billing alarms.
* cdn/terraform/cloudwatch.tf (alarm-estimated-charges-185-usd)
(alarm-estimated-charges-200-usd, alarm-estimated-charges-285-usd)
(alarm-estimated-charges-300-usd): Remove these alarms...
(alarm-estimated-charges-340-usd): ...and add this one.
---
cdn/terraform/cloudwatch.tf | 59 ++++-----------------------------------------
1 file changed, 5 insertions(+), 54 deletions(-)
diff --git a/cdn/terraform/cloudwatch.tf b/cdn/terraform/cloudwatch.tf
index 4b293ac..3ccff5b 100644
--- a/cdn/terraform/cloudwatch.tf
+++ b/cdn/terraform/cloudwatch.tf
@@ -1,8 +1,10 @@
# CloudWatch
-resource "aws_cloudwatch_metric_alarm" "alarm-estimated-charges-300-usd" {
- alarm_name = "alarm-estimated-charges-300-usd"
- alarm_description = "Estimated charges have exceeded 300 USD"
+# For the month of July, 2019, this threshold will give us 1 or 2 days
+# to react before we exceed the overall agreed-upon budget.
+resource "aws_cloudwatch_metric_alarm" "alarm-estimated-charges-340-usd" {
+ alarm_name = "alarm-estimated-charges-340-usd"
+ alarm_description = "Estimated charges have exceeded 340 USD"
namespace = "AWS/Billing"
metric_name = "EstimatedCharges"
statistic = "Maximum"
@@ -16,54 +18,3 @@ resource "aws_cloudwatch_metric_alarm"
"alarm-estimated-charges-300-usd" {
Currency = "USD"
}
}
-
-resource "aws_cloudwatch_metric_alarm" "alarm-estimated-charges-285-usd" {
- alarm_name = "alarm-estimated-charges-285-usd"
- alarm_description = "Estimated charges have exceeded 285 USD"
- namespace = "AWS/Billing"
- metric_name = "EstimatedCharges"
- statistic = "Maximum"
- period = "21600" # 6 hours
- evaluation_periods = "1"
- comparison_operator = "GreaterThanThreshold"
- threshold = "285"
- actions_enabled = true
- alarm_actions = ["${aws_sns_topic.guix-billing-alarms.arn}"]
- dimensions {
- Currency = "USD"
- }
-}
-
-resource "aws_cloudwatch_metric_alarm" "alarm-estimated-charges-200-usd" {
- alarm_name = "alarm-estimated-charges-200-usd"
- alarm_description = "Estimated charges have exceeded 200 USD"
- namespace = "AWS/Billing"
- metric_name = "EstimatedCharges"
- statistic = "Maximum"
- period = "21600" # 6 hours
- evaluation_periods = "1"
- comparison_operator = "GreaterThanThreshold"
- threshold = "200"
- actions_enabled = true
- alarm_actions = ["${aws_sns_topic.guix-billing-alarms.arn}"]
- dimensions {
- Currency = "USD"
- }
-}
-
-resource "aws_cloudwatch_metric_alarm" "alarm-estimated-charges-185-usd" {
- alarm_name = "alarm-estimated-charges-185-usd"
- alarm_description = "Estimated charges have exceeded 185 USD"
- namespace = "AWS/Billing"
- metric_name = "EstimatedCharges"
- statistic = "Maximum"
- period = "21600" # 6 hours
- evaluation_periods = "1"
- comparison_operator = "GreaterThanThreshold"
- threshold = "185"
- actions_enabled = true
- alarm_actions = ["${aws_sns_topic.guix-billing-alarms.arn}"]
- dimensions {
- Currency = "USD"
- }
-}