github.com/minamijoyo/terraform@v0.7.8-0.20161029001309-18b3736ba44b/website/source/docs/providers/librato/r/alert.html.markdown (about) 1 --- 2 layout: "librato" 3 page_title: "Librato: librato_alert" 4 sidebar_current: "docs-librato-resource-alert" 5 description: |- 6 Provides a Librato Alert resource. This can be used to create and manage alerts on Librato. 7 --- 8 9 # librato\_alert 10 11 Provides a Librato Alert resource. This can be used to 12 create and manage alerts on Librato. 13 14 ## Example Usage 15 16 ``` 17 # Create a new Librato alert 18 resource "librato_alert" "myalert" { 19 name = "MyAlert" 20 description = "A Test Alert" 21 services = [ "${librato_service.myservice.id}" ] 22 condition { 23 type = "above" 24 threshold = 10 25 metric_name = "librato.cpu.percent.idle" 26 } 27 } 28 ``` 29 30 ## Argument Reference 31 32 The following arguments are supported: 33 34 * `name` - (Required) The name of the alert. 35 * `description` - (Required) Description of the alert. 36 * `active` - whether the alert is active (can be triggered). Defaults to true. 37 * `rearm_seconds` - minimum amount of time between sending alert notifications, in seconds. 38 * `services` - list of notification service IDs. 39 * `condition` - A trigger condition for the alert. Conditions documented below. 40 * `attributes` - A hash of additional attribtues for the alert. Attributes documented below. 41 42 ## Attributes Reference 43 44 The following attributes are exported: 45 46 * `id` - The ID of the alert. 47 * `name` - The name of the alert. 48 * `description` - (Required) Description of the alert. 49 * `active` - whether the alert is active (can be triggered). Defaults to true. 50 * `rearm_seconds` - minimum amount of time between sending alert notifications, in seconds. 51 * `services` - list of notification service IDs. 52 * `condition` - A trigger condition for the alert. Conditions documented below. 53 54 Conditions (`condition`) support the following: 55 56 * `type` - The type of condition. Must be one of `above`, `below` or `absent`. 57 * `metric_name`- The name of the metric this alert condition applies to. 58 * `source`- A source expression which identifies which sources for the given metric to monitor. 59 * `detect_reset` - boolean: toggles the method used to calculate the delta from the previous sample when the summary_function is `derivative`. 60 * `duration` - number of seconds condition must be true to fire the alert (required for type `absent`). 61 * `threshold` - float: measurements over this number will fire the alert (only for `above` or `below`). 62 * `summary_function` - Indicates which statistic of an aggregated measurement to alert on. ((only for `above` or `below`). 63 64 Attributes (`attributes`) support the following: 65 66 * `runbook_url` - a URL for the runbook to be followed when this alert is firing. Used in the Librato UI if set.