Terraform module to configure Opsgenie Service Incident Rule
Create Opsgenie Team Routing Rule example
module "service_incident_rule" {
source = "cloudposse/incident-management/opsgenie//modules/service_incident_rule"
# Cloud Posse recommends pinning every module to a specific version
# version = "x.x.x"
service_incident_rule = {
service_id = "..."
incident_rule = {
condition_match_type = "match-all"
conditions = [
{
field = "tags"
operation = "contains"
expected_value = "expected1"
}
]
incident_properties = {
message = "This is a test message"
priority = "P3"
stakeholder_properties = {
message = "Message for stakeholders"
enable = true
}
}
}
}
}
Note: service_incident_rule
is a map for two reasons:
- to be able to put whole configuration in yaml file
- variables defined with type set are not robust enough (can't set default values)
Name | Default | Description | Required |
---|---|---|---|
service_incident_rule |
{} |
Opsgenie Service Incident Rule configuration | Yes |
Name | Description |
---|---|
service_incident_rule_id |
The ID of the Opsgenie Service Incident Rule |