Open ytanruengsri opened 9 years ago
Could you elaborate a bit more how this is supposed to work?
If you define a cloudwatch alarm in cloudfomation. You can normally define what actions (in AlarmActions
) are taken when the alarms changes state. And I would like to be able to send notification to a SNS Topic (see AlarmActions
)
Example:
"CPUAlarm" : {
"Type" : "AWS::CloudWatch::Alarm",
"Properties" : {
"AlarmDescription" : "CPU alarm for my instance",
"AlarmActions" : [ { "Ref" : "logical name of an AWS::SNS::Topic resource" }, { "Ref" : "logical name of an AWS::AutoScaling::ScalingPolicy" } ],
"MetricName" : "CPUUtilization",
"Namespace" : "AWS/EC2",
"Statistic" : "Average",
"Period" : "60",
"EvaluationPeriods" : "3",
"Threshold" : "90",
"ComparisonOperator" : "GreaterThanThreshold",
"Dimensions" : [ {
"Name" : "InstanceId",
"Value" : { "Ref" : "logical name of an AWS::EC2::Instance resource" }
} ]
}
}
Right now you can listen all cloudformation events and autoscaling events using the field
But you can't listen on cloudwatch alarms.
It would be great if these alarms could be linked to SNS