Skip to main content

Module: health-events

This module creates EventBridge (formerly CloudWatch Events) rules for AWS Personal Health Dashboard Events and an SNS topic. EventBridge will publish messages to this SNS topic, which can be subcribed to using this module as well. Since AWS Personal Health Dashboard is a global service, but since the KMS key and SNS topic are regional, this module is technically regional but only needs to be deployed once per account.

Usage

For a complete example, see examples/complete.

For automated tests of the complete example using bats and Terratest (which tests and deploys the example on AWS), see test.

Here's how to invoke this module in your projects:

module "monitor_yaml_config" {
source = "cloudposse/config/yaml"
# Cloud Posse recommends pinning every module to a specific version
# version = "x.x.x"

map_config_local_base_path = path.module
map_config_paths = ["catalog/event_rules/*.yaml"]

context = module.this.context
}

module "health_events" {
source = "cloudposse/health-events/aws"
# Cloud Posse recommends pinning every module to a specific version
# version = "x.x.x"

event_rules = module.event_rules_yaml_config.list_configs
subscribers = {
opsgenie = {
protocol = "https"
endpoint = "https://api.example.com/v1/"
endpoint_auto_confirms = true
raw_message_delivery = false
}
}

context = module.this.context
}

Examples

Here is an example of using this module: