• create - Create or update CloudWatch alarms.
  • delete - Delete CloudWatch alarms.
  • disable_action - Disable action of the CloudWatch alarms.
  • enable_action - Enable action of the CloudWatch alarms.


  • aws_secret_access_key, aws_access_key and optionally aws_session_token - required, unless using IAM roles for authentication.
  • alarm_name - the alarm name. If none is given on assignment, will take the resource name.
  • alarm_description - the description of alarm. Can be blank also.
  • actions_enabled - true for enable action on OK, ALARM or Insufficient data. if true, any of ok_actions, alarm_actions or insufficient_data_actions must be specified.
  • ok_actions - array of action if alarm state is OK. If specified actions_enabled must be true.
  • alarm_actions - array of action if alarm state is ALARM. If specified actions_enabled must be true.
  • insufficient_data_actions - array of action if alarm state is INSUFFICIENT_DATA. If specified actions_enabled must be true.
  • metric_name - CloudWatch metric name of the alarm. eg - CPUUtilization.Required parameter.
  • namespace - namespace of the alarm. eg - AWS/EC2, required parameter.
  • statistic - statistic of the alarm. Value must be in any of SampleCount, Average, Sum, Minimum or Maximum. Required parameter.
  • extended_statistic - extended_statistic of the alarm. Specify a value between p0.0 and p100. Optional parameter.
  • dimensions - dimensions for the metric associated with the alarm. Array of name and value.
  • period - in seconds, over which the specified statistic is applied. Integer type and required parameter.
  • unit - unit of measure for the statistic. Required parameter.
  • evaluation_periods - number of periods over which data is compared to the specified threshold. Required parameter.
  • threshold - value against which the specified statistic is compared. Can be float or integer type. Required parameter.
  • comparison_operator - arithmetic operation to use when comparing the specified statistic and threshold. The specified statistic value is used as the first operand.


aws_cloudwatch "kitchen_test_alarm" do
period 21600
evaluation_periods 2
threshold 50.0
comparison_operator "LessThanThreshold"
metric_name "CPUUtilization"
namespace "AWS/EC2"
statistic "Maximum"
dimensions [{"name" : "InstanceId", "value" : "i-xxxxxxx"}]
action :create




Research Intern at ISRO.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Create your test infrastructure with Genymotion Cloud SaaS and Terraform


Plan For Success Not Failure in FTTX Projects

Validator node FAQ

Should we all learn to code?

⚜𝐈𝐧𝐭𝐞𝐠𝐫𝐚𝐭𝐢𝐨𝐧 𝐨𝐟 𝐀𝐦𝐚𝐳𝐨𝐧 𝐑𝐃𝐒 𝐰𝐢𝐭𝐡 𝐌𝐮𝐥𝐭𝐢-𝐓𝐢𝐞𝐫…

Flutter || Build a vertical list of heterogeneous elements with horizontal list of homogeneous…

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Prishita Kapoor

Prishita Kapoor

Research Intern at ISRO.

More from Medium


The AWS Summit in the middle of Kreuzberg

AWS DMS Heartbeat — Avoid Critical Production DB Issues

How to create users and groups in AWS IAM service and assign permissions to users