Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
julienduchesne committed Nov 16, 2023
1 parent 877579b commit 434e3ad
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions docs/resources/notification_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,16 @@ resource "grafana_notification_policy" "my_notification_policy" {
match = "="
value = "myvalue"
}
matcher {
label = "alertname"
match = "="
value = "CPU Usage"
}
matcher {
label = "Name"
match = "=~"
value = "host.*|host-b.*"
}
contact_point = grafana_contact_point.a_contact_point.name
continue = true
mute_timings = [grafana_mute_timing.a_mute_timing.name]
Expand Down Expand Up @@ -118,7 +128,7 @@ Optional:
- `group_by` (List of String) A list of alert labels to group alerts into notifications by. Use the special label `...` to group alerts by all labels, effectively disabling grouping. Required for root policy only. If empty, the parent grouping is used.
- `group_interval` (String) Minimum time interval between two notifications for the same group. Default is 5 minutes.
- `group_wait` (String) Time to wait to buffer alerts of the same group before sending a notification. Default is 30 seconds.
- `matcher` (Block List) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--matcher))
- `matcher` (Block Set) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--matcher))
- `mute_timings` (List of String) A list of mute timing names to apply to alerts that match this policy.
- `policy` (Block List) Routing rules for specific label sets. (see [below for nested schema](#nestedblock--policy--policy))
- `repeat_interval` (String) Minimum time interval for re-sending a notification if an alert is still firing. Default is 4 hours.
Expand Down Expand Up @@ -146,7 +156,7 @@ Optional:
- `group_by` (List of String) A list of alert labels to group alerts into notifications by. Use the special label `...` to group alerts by all labels, effectively disabling grouping. Required for root policy only. If empty, the parent grouping is used.
- `group_interval` (String) Minimum time interval between two notifications for the same group. Default is 5 minutes.
- `group_wait` (String) Time to wait to buffer alerts of the same group before sending a notification. Default is 30 seconds.
- `matcher` (Block List) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--matcher))
- `matcher` (Block Set) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--matcher))
- `mute_timings` (List of String) A list of mute timing names to apply to alerts that match this policy.
- `policy` (Block List) Routing rules for specific label sets. (see [below for nested schema](#nestedblock--policy--policy--policy))
- `repeat_interval` (String) Minimum time interval for re-sending a notification if an alert is still firing. Default is 4 hours.
Expand Down Expand Up @@ -174,7 +184,7 @@ Optional:
- `group_by` (List of String) A list of alert labels to group alerts into notifications by. Use the special label `...` to group alerts by all labels, effectively disabling grouping. Required for root policy only. If empty, the parent grouping is used.
- `group_interval` (String) Minimum time interval between two notifications for the same group. Default is 5 minutes.
- `group_wait` (String) Time to wait to buffer alerts of the same group before sending a notification. Default is 30 seconds.
- `matcher` (Block List) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--policy--matcher))
- `matcher` (Block Set) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--policy--matcher))
- `mute_timings` (List of String) A list of mute timing names to apply to alerts that match this policy.
- `policy` (Block List) Routing rules for specific label sets. (see [below for nested schema](#nestedblock--policy--policy--policy--policy))
- `repeat_interval` (String) Minimum time interval for re-sending a notification if an alert is still firing. Default is 4 hours.
Expand Down Expand Up @@ -202,7 +212,7 @@ Optional:
- `continue` (Boolean) Whether to continue matching subsequent rules if an alert matches the current rule. Otherwise, the rule will be 'consumed' by the first policy to match it.
- `group_interval` (String) Minimum time interval between two notifications for the same group. Default is 5 minutes.
- `group_wait` (String) Time to wait to buffer alerts of the same group before sending a notification. Default is 30 seconds.
- `matcher` (Block List) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--policy--policy--matcher))
- `matcher` (Block Set) Describes which labels this rule should match. When multiple matchers are supplied, an alert must match ALL matchers to be accepted by this policy. When no matchers are supplied, the rule will match all alert instances. (see [below for nested schema](#nestedblock--policy--policy--policy--policy--matcher))
- `mute_timings` (List of String) A list of mute timing names to apply to alerts that match this policy.
- `repeat_interval` (String) Minimum time interval for re-sending a notification if an alert is still firing. Default is 4 hours.

Expand Down

0 comments on commit 434e3ad

Please sign in to comment.