generated from cloudposse/terraform-example-module
-
-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Opsgenie
service
, service_incident_rule
and user
modules an…
…d tests. Update `team` module (#10) * Add `Opsgenie User` module, example, and test * Update `Opsgenie Team` * Update `Opsgenie Team` * Add `Opsgenie Service` module, example and test * Add `Opsgenie Service` module, example and test * Add `Opsgenie Service` module, example and test * Add `Opsgenie Service` module, example and test * Add `Opsgenie Service Incident Rule` module, example and test * Add `Opsgenie Service Incident Rule` module, example and test * Add `Opsgenie Service Incident Rule` module, example and test * Add `Opsgenie Service Incident Rule` module, example and test * Add `Opsgenie Service Incident Rule` module, example and test * Update tests * Update tests * Update tests * Update tests
- Loading branch information
Showing
68 changed files
with
1,506 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,84 @@ | ||
output "escalation_id" { | ||
description = "The ID of the Opsgenie escalation" | ||
value = module.escalation.escalation_id | ||
} | ||
|
||
output "escalation_name" { | ||
description = "The Name of the Opsgenie escalation" | ||
description = "The name of the Opsgenie escalation" | ||
value = module.escalation.escalation_name | ||
} | ||
|
||
output "escalation_id" { | ||
description = "The ID of the Opsgenie escalation" | ||
value = module.escalation.escalation_id | ||
output "api_integration_id" { | ||
description = "The ID of the Opsgenie integration" | ||
value = module.api_integration.api_integration_id | ||
} | ||
|
||
output "api_integration_name" { | ||
description = "The name of the Opsgenie integration" | ||
value = module.api_integration.api_integration_name | ||
} | ||
|
||
output "alert_policy_id" { | ||
description = "The ID of the Opsgenie policy" | ||
value = module.alert_policy.alert_policy_id | ||
} | ||
|
||
output "alert_policy_name" { | ||
description = "The name of the Opsgenie policy" | ||
value = module.alert_policy.alert_policy_name | ||
} | ||
|
||
output "notification_policy_id" { | ||
description = "The ID of the Opsgenie notification policy" | ||
value = module.notification_policy.notification_policy_id | ||
} | ||
|
||
output "notification_policy_name" { | ||
description = "The name of the Opsgenie notification policy" | ||
value = module.notification_policy.notification_policy_name | ||
} | ||
|
||
output "team_routing_rule_id" { | ||
description = "The ID of the Opsgenie team routing rule" | ||
value = module.team_routing_rule.team_routing_rule_id | ||
} | ||
|
||
output "team_routing_rule_name" { | ||
description = "The name of the Opsgenie team routing rule" | ||
value = module.team_routing_rule.team_routing_rule_name | ||
} | ||
|
||
output "team_id" { | ||
description = "The ID of the Opsgenie team" | ||
value = module.team.team_id | ||
} | ||
|
||
output "team_name" { | ||
description = "The name of the Opsgenie team" | ||
value = module.team.team_name | ||
} | ||
|
||
output "user_id" { | ||
description = "The ID of the Opsgenie user" | ||
value = module.user.user_id | ||
} | ||
|
||
output "user_name" { | ||
description = "The name of the Opsgenie user" | ||
value = module.user.user_name | ||
} | ||
|
||
output "service_id" { | ||
description = "The ID of the Opsgenie service" | ||
value = module.service.service_id | ||
} | ||
|
||
output "service_name" { | ||
description = "The name of the Opsgenie service" | ||
value = module.service.service_name | ||
} | ||
|
||
output "service_incident_rule_id" { | ||
description = "The ID of the Opsgenie service incident rule" | ||
value = module.service_incident_rule.service_incident_rule_id | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
module "service" { | ||
source = "../../modules/service" | ||
|
||
# Services are Opsgenie Enterprise feature, disable it for now | ||
enabled = false | ||
|
||
service = { | ||
name = "frontend" | ||
description = "Frontend service" | ||
team_id = module.team.team_id | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
module "service_incident_rule" { | ||
source = "../../modules/service_incident_rule" | ||
|
||
# Services are Opsgenie Enterprise feature, disable it for now | ||
enabled = false | ||
|
||
service_incident_rule = { | ||
service_id = module.service.service_id | ||
|
||
incident_rule = { | ||
condition_match_type = "match-all" | ||
|
||
conditions = [ | ||
{ | ||
# Possibke values: message, description, tags, extra-properties, recipients, teams, priority | ||
field = "message" | ||
operation = "matches" | ||
expected_value = ".*stage.*" | ||
}, | ||
{ | ||
field = "tags" | ||
operation = "contains" | ||
expected_value = "severity:info" | ||
} | ||
] | ||
|
||
incident_properties = { | ||
message = "This is a test message" | ||
priority = "P3" | ||
|
||
stakeholder_properties = { | ||
message = "Message for stakeholders" | ||
enable = true | ||
} | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module "user" { | ||
source = "../../modules/user" | ||
|
||
# Users can't be destroyed | ||
enabled = false | ||
|
||
user = { | ||
username = "[email protected]" | ||
full_name = "Opsgenie Test User" | ||
role = "User" | ||
locale = "en_US" | ||
timezone = "America/New_York" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.