From 0f6656fd0c0074b0bdea635e38c65d249c743cde Mon Sep 17 00:00:00 2001 From: Rizal Widyarta Gowandy Date: Tue, 31 Aug 2021 12:22:45 +0700 Subject: [PATCH 1/2] Add Alert Runbook URL Useful to debug directly to the log file. --- main.tf | 1 + variables.tf | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/main.tf b/main.tf index 146ca07..ef1b1a3 100644 --- a/main.tf +++ b/main.tf @@ -838,6 +838,7 @@ resource "newrelic_nrql_alert_condition" "main" { type = "static" name = "[CRITICAL] Error Rate ${var.event_method_substring != "" ? replace(each.key, var.event_method_substring, var.event_method_replace) : each.key}" description = "Alert when error rate is above normal condition" + runbook_url = var.runbook_url enabled = var.enable_alert violation_time_limit_seconds = 3600 value_function = "single_value" diff --git a/variables.tf b/variables.tf index 0f795ff..ac5d129 100644 --- a/variables.tf +++ b/variables.tf @@ -36,4 +36,8 @@ variable "policy_id" { variable "enable_alert" { type = bool -} \ No newline at end of file +} + +variable "runbook_url" { + type = string +} From a7e374a90348f438d96225b5719eb65b7fc83093 Mon Sep 17 00:00:00 2001 From: Rizal Widyarta Gowandy Date: Tue, 31 Aug 2021 12:25:31 +0700 Subject: [PATCH 2/2] Update README --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 0917d07..860078b 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,9 @@ module "grpc_dashboard" { # Set true to enable alert. enable_alert = false + # Set to your application log management or confluence. + runbook_url = "http://www.scalyr.com" + # Replace with your dashboard name, should be unique for your account. dashboard_name = "app_grpc" service_name = "app_grpc"