mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
[docs/sources/alerting] Replace docs/reference shortcode with ref URIs (#88079)
This commit is contained in:
parent
fe78563faa
commit
410e3b17e9
@ -18,6 +18,52 @@ labels:
|
||||
- oss
|
||||
title: Configure Grafana-managed alert rules
|
||||
weight: 100
|
||||
refs:
|
||||
time-units-and-relative-ranges:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/dashboards/use-dashboards/#time-units-and-relative-ranges
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/visualizations/dashboards/use-dashboards/#time-units-and-relative-ranges
|
||||
fundamentals:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/
|
||||
alert-instance-state:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-instance-state
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-instance-state
|
||||
keep-last-state:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/#keep-last-state
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/#keep-last-state
|
||||
add-a-query:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data/#add-a-query
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data/#add-a-query
|
||||
pending-period:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/#pending-period
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/#pending-period
|
||||
alerting-on-numeric-data:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions/#alert-on-numeric-data
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions/#alert-on-numeric-data
|
||||
expression-queries:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data/expression-queries/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data/expression-queries/
|
||||
annotation-label:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label/
|
||||
---
|
||||
|
||||
# Configure Grafana-managed alert rules
|
||||
@ -56,7 +102,7 @@ To get started quickly, refer to our [tutorial on getting started with Grafana a
|
||||
Define a query to get the data you want to measure and a condition that needs to be met before an alert rule fires.
|
||||
|
||||
1. Select a data source.
|
||||
1. From the **Options** dropdown, specify a [time range][time-units-and-relative-ranges].
|
||||
1. From the **Options** dropdown, specify a [time range](ref:time-units-and-relative-ranges).
|
||||
|
||||
**Note:**
|
||||
|
||||
@ -66,11 +112,11 @@ Define a query to get the data you want to measure and a condition that needs to
|
||||
|
||||
1. Add a query.
|
||||
|
||||
To add multiple [queries][add-a-query], click **Add query**.
|
||||
To add multiple [queries](ref:add-a-query), click **Add query**.
|
||||
|
||||
All alert rules are managed by Grafana by default. If you want to switch to a data source-managed alert rule, click **Switch to data source-managed alert rule**.
|
||||
|
||||
1. Add one or more [expressions][expression-queries].
|
||||
1. Add one or more [expressions](ref:expression-queries).
|
||||
|
||||
a. For each expression, select either **Classic condition** to create a single alert rule, or choose from the **Math**, **Reduce**, and **Resample** options to generate separate alert for each series.
|
||||
|
||||
@ -160,24 +206,24 @@ Complete the following steps to set up labels and notifications.
|
||||
|
||||
## Add annotations
|
||||
|
||||
Add [annotations][annotation-label]. to provide more context on the alert in your alert notification message.
|
||||
Add [annotations](ref:annotation-label). to provide more context on the alert in your alert notification message.
|
||||
|
||||
Annotations add metadata to provide more information on the alert in your alert notification message. For example, add a **Summary** annotation to tell you which value caused the alert to fire or which server it happened on.
|
||||
|
||||
1. [Optional] Add a summary.
|
||||
1. Optional: Add a summary.
|
||||
|
||||
Short summary of what happened and why.
|
||||
|
||||
1. [Optional] Add a description.
|
||||
1. Optional: Add a description.
|
||||
|
||||
Description of what the alert rule does.
|
||||
|
||||
1. [Optional] Add a Runbook URL.
|
||||
1. Optional: Add a Runbook URL.
|
||||
|
||||
Webpage where you keep your runbook for the alert
|
||||
|
||||
1. [Optional] Add a custom annotation
|
||||
1. [Optional] Add a **dashboard and panel link**.
|
||||
1. Optional: Add a custom annotation
|
||||
1. Optional: Add a **dashboard and panel link**.
|
||||
|
||||
Links alerts to panels in a dashboard.
|
||||
|
||||
@ -189,25 +235,25 @@ Annotations add metadata to provide more information on the alert in your alert
|
||||
|
||||
In **Configure no data and error handling**, you can define the alerting behavior when the evaluation returns no data or an error.
|
||||
|
||||
For details about alert states, refer to [lifecycle of alert instances.][alert-instance-state]
|
||||
For details about alert states, refer to [lifecycle of alert instances.](ref:alert-instance-state)
|
||||
|
||||
You can configure the alert instance state when its evaluation returns no data:
|
||||
|
||||
| No Data configuration | Description |
|
||||
| --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| No Data | The default option. Sets alert instance state to `No data`. <br/> The alert rule also creates a new alert instance `DatasourceNoData` with the name and UID of the alert rule, and UID of the datasource that returned no data as labels. |
|
||||
| Alerting | Sets alert instance state to `Alerting`. It waits until the [pending period][pending-period] has finished. |
|
||||
| Alerting | Sets alert instance state to `Alerting`. It waits until the [pending period](ref:pending-period) has finished. |
|
||||
| Ok | Sets alert instance state to `Normal`. |
|
||||
| Keep Last State | Maintains the alert instance in its last state. Useful for mitigating temporary issues, refer to [Keep last state][keep-last-state]. |
|
||||
| Keep Last State | Maintains the alert instance in its last state. Useful for mitigating temporary issues, refer to [Keep last state](ref:keep-last-state). |
|
||||
|
||||
You can also configure the alert instance state when its evaluation returns an error or timeout.
|
||||
|
||||
| Error configuration | Description |
|
||||
| ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| Error | The default option. Sets alert instance state to `Error`. <br/> The alert rule also creates a new alert instance `DatasourceError` with the name and UID of the alert rule, and UID of the datasource that returned no data as labels. |
|
||||
| Alerting | Sets alert instance state to `Alerting`. It waits until the [pending period][pending-period] has finished. |
|
||||
| Alerting | Sets alert instance state to `Alerting`. It waits until the [pending period](ref:pending-period) has finished. |
|
||||
| Ok | Sets alert instance state to `Normal`. |
|
||||
| Keep Last State | Maintains the alert instance in its last state. Useful for mitigating temporary issues, refer to [Keep last state][keep-last-state]. |
|
||||
| Keep Last State | Maintains the alert instance in its last state. Useful for mitigating temporary issues, refer to [Keep last state](ref:keep-last-state). |
|
||||
|
||||
## Create alerts from panels
|
||||
|
||||
@ -218,33 +264,3 @@ Create alerts from any panel type. This means you can reuse the queries in the p
|
||||
3. From the dropdown menu, select **More...** and then choose **New alert rule**.
|
||||
|
||||
This will open the alert rule form, allowing you to configure and create your alert based on the current panel's query.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[add-a-query]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data#add-a-query"
|
||||
[add-a-query]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data#add-a-query"
|
||||
|
||||
[alerting-on-numeric-data]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions#alert-on-numeric-data"
|
||||
[alerting-on-numeric-data]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions#alert-on-numeric-data"
|
||||
|
||||
[annotation-label]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label"
|
||||
[annotation-label]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label"
|
||||
|
||||
[expression-queries]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data/expression-queries"
|
||||
[expression-queries]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data/expression-queries"
|
||||
|
||||
[fundamentals]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals"
|
||||
[fundamentals]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals"
|
||||
|
||||
[time-units-and-relative-ranges]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/dashboards/use-dashboards#time-units-and-relative-ranges"
|
||||
[time-units-and-relative-ranges]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/visualizations/dashboards/use-dashboards#time-units-and-relative-ranges"
|
||||
|
||||
[pending-period]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation#pending-period"
|
||||
[pending-period]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation#pending-period"
|
||||
|
||||
[keep-last-state]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health#keep-last-state"
|
||||
[keep-last-state]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health#keep-last-state"
|
||||
|
||||
[alert-instance-state]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-instance-state"
|
||||
[alert-instance-state]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-instance-state"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
|
@ -18,6 +18,15 @@ labels:
|
||||
- oss
|
||||
title: Create recording rules
|
||||
weight: 300
|
||||
refs:
|
||||
configure-grafana:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/setup-grafana/configure-grafana/
|
||||
annotation-label:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label/
|
||||
---
|
||||
|
||||
# Create recording rules
|
||||
@ -31,7 +40,7 @@ For more information on recording rules in Prometheus, refer to [Defining record
|
||||
|
||||
Recording rules are run as instant rules, which means that they run every 10s. To overwrite this configuration, update the min_interval in your custom configuration file.
|
||||
|
||||
[min_interval][configure-grafana] sets the minimum interval to enforce between rule evaluations. The default value is 10s which equals the scheduler interval. Rules will be adjusted if they are less than this value or if they are not multiple of the scheduler interval (10s). Higher values can help with resource management as fewer evaluations are scheduled over time.
|
||||
[min_interval](ref:configure-grafana) sets the minimum interval to enforce between rule evaluations. The default value is 10s which equals the scheduler interval. Rules will be adjusted if they are less than this value or if they are not multiple of the scheduler interval (10s). Higher values can help with resource management as fewer evaluations are scheduled over time.
|
||||
|
||||
This setting has precedence over each individual rule frequency. If a rule frequency is lower than this value, then this value is enforced.
|
||||
|
||||
@ -67,10 +76,3 @@ To create recording rules, follow these steps.
|
||||
1. Add labels.
|
||||
- Add custom labels selecting existing key-value pairs from the drop down, or add new labels by entering the new key or value .
|
||||
1. Click **Save rule** to save the rule or **Save rule and exit** to save the rule and go back to the Alerting page.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[annotation-label]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label"
|
||||
[annotation-label]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label"
|
||||
|
||||
[configure-grafana]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/setup-grafana/configure-grafana"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -18,6 +18,17 @@ labels:
|
||||
- oss
|
||||
title: Configure data source-managed alert rules
|
||||
weight: 200
|
||||
refs:
|
||||
alerting:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/
|
||||
annotation-label:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label/
|
||||
---
|
||||
|
||||
# Configure data source-managed alert rules
|
||||
@ -102,35 +113,27 @@ All alert rules and instances, irrespective of their labels, match the default n
|
||||
|
||||
## Add annotations
|
||||
|
||||
Add [annotations][annotation-label]. to provide more context on the alert in your alert notifications.
|
||||
Add [annotations](ref:annotation-label). to provide more context on the alert in your alert notifications.
|
||||
|
||||
Annotations add metadata to provide more information on the alert in your alert notifications. For example, add a **Summary** annotation to tell you which value caused the alert to fire or which server it happened on.
|
||||
|
||||
1. [Optional] Add a summary.
|
||||
1. Optional: Add a summary.
|
||||
|
||||
Short summary of what happened and why.
|
||||
|
||||
1. [Optional] Add a description.
|
||||
1. Optional: Add a description.
|
||||
|
||||
Description of what the alert rule does.
|
||||
|
||||
1. [Optional] Add a Runbook URL.
|
||||
1. Optional: Add a Runbook URL.
|
||||
|
||||
Webpage where you keep your runbook for the alert
|
||||
|
||||
1. [Optional] Add a custom annotation
|
||||
1. [Optional] Add a **dashboard and panel link**.
|
||||
1. Optional: Add a custom annotation
|
||||
1. Optional: Add a **dashboard and panel link**.
|
||||
|
||||
Links alerts to panels in a dashboard.
|
||||
|
||||
{{< docs/play title="visualizations with linked alerts in Grafana" url="https://play.grafana.org/d/000000074/" >}}
|
||||
|
||||
1. Click **Save rule**.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[alerting]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting"
|
||||
[alerting]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting"
|
||||
|
||||
[annotation-label]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label"
|
||||
[annotation-label]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -16,6 +16,10 @@ labels:
|
||||
- oss
|
||||
title: Template labels and annotations
|
||||
weight: 500
|
||||
refs:
|
||||
explore:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/explore/
|
||||
---
|
||||
|
||||
# Template labels and annotations
|
||||
@ -294,7 +298,7 @@ https://example.com/grafana
|
||||
|
||||
### graphLink
|
||||
|
||||
The `graphLink` function returns the path to the graphical view in [Explore][explore] for the given expression and data source:
|
||||
The `graphLink` function returns the path to the graphical view in [Explore](ref:explore) for the given expression and data source:
|
||||
|
||||
```
|
||||
{{ graphLink "{\"expr\": \"up\", \"datasource\": \"gdev-prometheus\"}" }}
|
||||
@ -390,7 +394,7 @@ The `pathPrefix` function returns the path of the Grafana server as configured i
|
||||
|
||||
### tableLink
|
||||
|
||||
The `tableLink` function returns the path to the tabular view in [Explore][explore] for the given expression and data source:
|
||||
The `tableLink` function returns the path to the tabular view in [Explore](ref:explore) for the given expression and data source:
|
||||
|
||||
```
|
||||
{{ tableLink "{\"expr\": \"up\", \"datasource\": \"gdev-prometheus\"}" }}
|
||||
@ -447,7 +451,3 @@ The `reReplaceAll` function replaces text matching the regular expression:
|
||||
```
|
||||
example.com:8080
|
||||
```
|
||||
|
||||
{{% docs/reference %}}
|
||||
[explore]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/explore"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -13,25 +13,30 @@ labels:
|
||||
menuTitle: Configure notifications
|
||||
title: Configure notifications
|
||||
weight: 125
|
||||
refs:
|
||||
contact-points:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points/
|
||||
notification-policies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies/
|
||||
templates-page:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/templates/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/templates/
|
||||
---
|
||||
|
||||
# Configure notifications
|
||||
|
||||
Choose how, when, and where to send your alert notifications.
|
||||
|
||||
As a first step, define your [contact points][contact-points] where to send your alert notifications to. A contact point is a set of one or more integrations that are used to deliver notifications.
|
||||
As a first step, define your [contact points](ref:contact-points) where to send your alert notifications to. A contact point is a set of one or more integrations that are used to deliver notifications.
|
||||
|
||||
Next, create a [notification policy][notification-policies] which is a set of rules for where, when and how your alerts are routed to contact points. In a notification policy, you define where to send your alert notifications by choosing one of the contact points you created.
|
||||
Next, create a [notification policy](ref:notification-policies) which is a set of rules for where, when and how your alerts are routed to contact points. In a notification policy, you define where to send your alert notifications by choosing one of the contact points you created.
|
||||
|
||||
Optionally, you can add [notification templates][templates-page] to contact points for reuse and consistent messaging in your notifications.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[notification-policies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies"
|
||||
[notification-policies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies"
|
||||
|
||||
[contact-points]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points"
|
||||
[contact-points]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points"
|
||||
|
||||
[templates-page]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/templates/"
|
||||
[templates-page]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/templates/"
|
||||
{{% /docs/reference %}}
|
||||
Optionally, you can add [notification templates](ref:templates-page) to contact points for reuse and consistent messaging in your notifications.
|
||||
|
@ -19,6 +19,12 @@ labels:
|
||||
- oss
|
||||
title: Configure notification policies
|
||||
weight: 420
|
||||
refs:
|
||||
notification-policies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies/
|
||||
---
|
||||
|
||||
# Configure notification policies
|
||||
@ -33,7 +39,7 @@ If the **Continue matching subsequent sibling nodes** option is enabled for a ne
|
||||
|
||||
You can configure Grafana-managed notification policies as well as notification policies for an external Alertmanager data source.
|
||||
|
||||
For more information on notification policies, refer to [fundamentals of Notification Policies][notification-policies].
|
||||
For more information on notification policies, refer to [fundamentals of Notification Policies](ref:notification-policies).
|
||||
|
||||
## Edit default notification policy
|
||||
|
||||
@ -110,8 +116,3 @@ An example of an alert configuration.
|
||||
- Create specific route for alerts coming from the development cluster with an appropriate contact point.
|
||||
- Create a specific route for alerts with "critical" severity with a more invasive contact point integration, like pager duty notification.
|
||||
- Create specific routes for particular teams that handle their own on-call rotations.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[notification-policies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies"
|
||||
[notification-policies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -25,6 +25,27 @@ labels:
|
||||
- oss
|
||||
title: Configure contact points
|
||||
weight: 410
|
||||
refs:
|
||||
webhook:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier/
|
||||
pagerduty:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/pager-duty/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/pager-duty/
|
||||
oncall:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-oncall/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-oncall/
|
||||
slack:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-slack/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-slack/
|
||||
---
|
||||
|
||||
# Configure contact points
|
||||
@ -106,46 +127,25 @@ After you have configured an integration, you can use it as part of your contact
|
||||
|
||||
## List of supported integrations
|
||||
|
||||
| Name | Type |
|
||||
| ------------------------ | ------------------------- |
|
||||
| DingDing | `dingding` |
|
||||
| Discord | `discord` |
|
||||
| [Email][email] | `email` |
|
||||
| Google Chat | `googlechat` |
|
||||
| [Grafana Oncall][oncall] | `oncall` |
|
||||
| Hipchat | `hipchat` |
|
||||
| Kafka | `kafka` |
|
||||
| Line | `line` |
|
||||
| Microsoft Teams | `teams` |
|
||||
| Opsgenie | `opsgenie` |
|
||||
| [Pagerduty][pagerduty] | `pagerduty` |
|
||||
| Prometheus Alertmanager | `prometheus-alertmanager` |
|
||||
| Pushover | `pushover` |
|
||||
| Sensu | `sensu` |
|
||||
| Sensu Go | `sensugo` |
|
||||
| [Slack][slack] | `slack` |
|
||||
| [Telegram][telegram] | `telegram` |
|
||||
| Threema | `threema` |
|
||||
| VictorOps | `victorops` |
|
||||
| [Webhook][webhook] | `webhook` |
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[email]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-email"
|
||||
[email]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-email"
|
||||
|
||||
[oncall]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-oncall"
|
||||
[oncall]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-oncall"
|
||||
|
||||
[pagerduty]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/pager-duty"
|
||||
[pagerduty]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/pager-duty"
|
||||
|
||||
[slack]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-slack"
|
||||
[slack]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-slack"
|
||||
|
||||
[telegram]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-telegram"
|
||||
[telegram]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-telegram"
|
||||
|
||||
[webhook]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier"
|
||||
[webhook]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier"
|
||||
{{% /docs/reference %}}
|
||||
| Name | Type |
|
||||
| ---------------------------- | ------------------------- |
|
||||
| DingDing | `dingding` |
|
||||
| Discord | `discord` |
|
||||
| Email | `email` |
|
||||
| Google Chat | `googlechat` |
|
||||
| [Grafana Oncall](ref:oncall) | `oncall` |
|
||||
| Hipchat | `hipchat` |
|
||||
| Kafka | `kafka` |
|
||||
| Line | `line` |
|
||||
| Microsoft Teams | `teams` |
|
||||
| Opsgenie | `opsgenie` |
|
||||
| [Pagerduty](ref:pagerduty) | `pagerduty` |
|
||||
| Prometheus Alertmanager | `prometheus-alertmanager` |
|
||||
| Pushover | `pushover` |
|
||||
| Sensu | `sensu` |
|
||||
| Sensu Go | `sensugo` |
|
||||
| [Slack](ref:slack) | `slack` |
|
||||
| Telegram | `telegram` |
|
||||
| Threema | `threema` |
|
||||
| VictorOps | `victorops` |
|
||||
| [Webhook](ref:webhook) | `webhook` |
|
||||
|
@ -19,13 +19,29 @@ labels:
|
||||
menuTitle: Grafana OnCall
|
||||
title: Configure Grafana OnCall for Alerting
|
||||
weight: 300
|
||||
refs:
|
||||
oncall-integration:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/oncall/latest/integrations/grafana-alerting/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/oncall/integrations/grafana-alerting/
|
||||
create-notification-policy:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy/
|
||||
escalation-chain:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/oncall/latest/configure/escalation-chains-and-routes/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/oncall/configure/escalation-chains-and-routes/
|
||||
---
|
||||
|
||||
## Configure Grafana OnCall for Alerting
|
||||
|
||||
Use the Grafana Alerting - Grafana OnCall integration to effortlessly connect alerts generated by Grafana Alerting with Grafana OnCall, where you can then route them according to defined escalation chains and schedules.
|
||||
|
||||
You can set up the integration using the Grafana Alerting application or the Grafana OnCall application. For more information on setting it up from the Grafana OnCall application, see [Grafana OnCall documentation][oncall-integration].
|
||||
You can set up the integration using the Grafana Alerting application or the Grafana OnCall application. For more information on setting it up from the Grafana OnCall application, see [Grafana OnCall documentation](ref:oncall-integration).
|
||||
|
||||
### Before you begin
|
||||
|
||||
@ -59,19 +75,8 @@ To set up the Grafana OnCall integration using the Grafana Alerting application,
|
||||
1. Connect your contact point to a notification policy.
|
||||
|
||||
For more information on connecting your contact point to a notification policy, see
|
||||
[Create notification policy][create-notification-policy].
|
||||
[Create notification policy](ref:create-notification-policy).
|
||||
|
||||
1. To view your integration in the Grafana OnCall application and set up routes and escalation chains, click the Link next to the integration on the Contact points list view page in the **Type** column.
|
||||
|
||||
This redirects you to the Grafana OnCall integration page in the Grafana OnCall application. From there, you can add [routes and escalation chains][escalation-chain].
|
||||
|
||||
{{% docs/reference %}}
|
||||
[create-notification-policy]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy"
|
||||
[create-notification-policy]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy"
|
||||
|
||||
[oncall-integration]: "/docs/grafana/ -> /docs/oncall/latest/integrations/grafana-alerting"
|
||||
[oncall-integration]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/oncall/integrations/grafana-alerting"
|
||||
|
||||
[escalation-chain]: "/docs/grafana/ -> /docs/oncall/latest/configure/escalation-chains-and-routes"
|
||||
[escalation-chain]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/oncall/configure/escalation-chains-and-routes"
|
||||
{{% /docs/reference %}}
|
||||
This redirects you to the Grafana OnCall integration page in the Grafana OnCall application. From there, you can add [routes and escalation chains](ref:escalation-chain).
|
||||
|
@ -14,6 +14,12 @@ labels:
|
||||
menuTitle: Slack
|
||||
title: Configure Slack for Alerting
|
||||
weight: 300
|
||||
refs:
|
||||
nested-policy:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy/#add-new-nested-policy
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy/#add-new-nested-policy
|
||||
---
|
||||
|
||||
# Configure Slack for Alerting
|
||||
@ -84,10 +90,4 @@ To add the contact point and integration you created to your default notificatio
|
||||
1. Click **Update default policy**.
|
||||
|
||||
**Note:**
|
||||
If you have more than one contact point, add a new notification policy rather than edit the default one, so you can route specific alerts to Slack. For more information, refer to [Notification policies][nested-policy].
|
||||
|
||||
{{% docs/reference %}}
|
||||
[nested-policy]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy#add-new-nested-policy"
|
||||
|
||||
[nested-policy]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy#add-new-nested-policy"
|
||||
{{% /docs/reference %}}
|
||||
If you have more than one contact point, add a new notification policy rather than edit the default one, so you can route specific alerts to Slack. For more information, refer to [Notification policies](ref:nested-policy).
|
||||
|
@ -19,6 +19,17 @@ labels:
|
||||
- oss
|
||||
title: Configure mute timings
|
||||
weight: 450
|
||||
refs:
|
||||
datasources/alertmanager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/datasources/alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/connect-externally-hosted/data-sources/alertmanager/
|
||||
intro-alertmanager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager/
|
||||
---
|
||||
|
||||
# Configure mute timings
|
||||
@ -27,7 +38,7 @@ A mute timing is a recurring interval of time when no new notifications for a po
|
||||
|
||||
Similar to silences, mute timings do not prevent alert rules from being evaluated, nor do they stop alert instances from being shown in the user interface. They only prevent notifications from being created.
|
||||
|
||||
You can configure Grafana managed mute timings as well as mute timings for an [external Alertmanager data source][datasources/alertmanager]. For more information, refer to [Alertmanager documentation][intro-alertmanager].
|
||||
You can configure Grafana managed mute timings as well as mute timings for an [external Alertmanager data source](ref:datasources/alertmanager). For more information, refer to [Alertmanager documentation](ref:intro-alertmanager).
|
||||
|
||||
## Mute timings vs silences
|
||||
|
||||
@ -80,11 +91,3 @@ If you want to specify an exact duration, specify all the options. For example,
|
||||
- Days of the week: `monday`
|
||||
- Months: `3, 6, 9, 12`
|
||||
- Days of the month: `1:7`
|
||||
|
||||
{{% docs/reference %}}
|
||||
[datasources/alertmanager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/datasources/alertmanager"
|
||||
[datasources/alertmanager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/connect-externally-hosted/data-sources/alertmanager"
|
||||
|
||||
[intro-alertmanager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager"
|
||||
[intro-alertmanager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -15,6 +15,22 @@ labels:
|
||||
- oss
|
||||
title: Configure notification messages
|
||||
weight: 430
|
||||
refs:
|
||||
use-notification-templates:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/use-notification-templates/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/use-notification-templates/
|
||||
reference:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference/
|
||||
using-go-templating-language:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/using-go-templating-language/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/using-go-templating-language/
|
||||
---
|
||||
|
||||
# Configure notification messages
|
||||
@ -36,27 +52,16 @@ However, there are limitations. You cannot:
|
||||
|
||||
## Learn more
|
||||
|
||||
[Using Go's templating language][using-go-templating-language]
|
||||
[Using Go's templating language](ref:using-go-templating-language)
|
||||
|
||||
Learn how to write the content of your notification templates in Go’s templating language.
|
||||
|
||||
Create reusable notification templates for your contact points.
|
||||
|
||||
[Use notification templates][use-notification-templates]
|
||||
[Use notification templates](ref:use-notification-templates)
|
||||
|
||||
Use notification templates to send notifications to your contact points.
|
||||
|
||||
[Reference][reference]
|
||||
[Reference](ref:reference)
|
||||
|
||||
Data that is available when writing templates.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[reference]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference"
|
||||
[reference]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference"
|
||||
|
||||
[use-notification-templates]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/use-notification-templates"
|
||||
[use-notification-templates]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/use-notification-templates"
|
||||
|
||||
[using-go-templating-language]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/using-go-templating-language"
|
||||
[using-go-templating-language]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/using-go-templating-language"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -65,7 +65,7 @@ To preview your notification templates:
|
||||
|
||||
Default data is provided and you can add or edit alert data to it as well as alert instances. You can add alert data directly in the Payload data window itself or click **Select alert instances** or **Add custom alerts**.
|
||||
|
||||
1. [Optional] To add alert data from existing alert instances:
|
||||
1. Optional: To add alert data from existing alert instances:
|
||||
|
||||
a. Click **Select alert instances**.
|
||||
|
||||
@ -73,7 +73,7 @@ To preview your notification templates:
|
||||
|
||||
c. Click **Confirm** to add the alert instance(s) to the payload.
|
||||
|
||||
1. [Optional] To add alert data using the Alert data editor, click **Add custom data:**
|
||||
1. Optional: To add alert data using the Alert data editor, click **Add custom data:**
|
||||
|
||||
a. Add annotations, custom labels and/or set a dashboard or a panel.
|
||||
|
||||
|
@ -16,6 +16,17 @@ labels:
|
||||
- oss
|
||||
title: Use notification templates
|
||||
weight: 300
|
||||
refs:
|
||||
create-notification-templates:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/create-notification-templates/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/create-notification-templates/
|
||||
using-go-templating-language:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/using-go-templating-language/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/using-go-templating-language/
|
||||
---
|
||||
|
||||
# Use notification templates
|
||||
@ -32,14 +43,6 @@ In the Contact points tab, you can see a list of your contact points.
|
||||
|
||||
{{< figure max-width="940px" src="/static/img/docs/alerting/unified/use-notification-template-9-4.png" caption="Use notification template" >}}
|
||||
|
||||
For more information on how to write and execute templates, refer to [Using Go's templating language][using-go-templating-language] and [Create notification templates][create-notification-templates].
|
||||
For more information on how to write and execute templates, refer to [Using Go's templating language](ref:using-go-templating-language) and [Create notification templates](ref:create-notification-templates).
|
||||
|
||||
1. Click **Save contact point**.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[create-notification-templates]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/create-notification-templates"
|
||||
[create-notification-templates]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/create-notification-templates"
|
||||
|
||||
[using-go-templating-language]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/using-go-templating-language"
|
||||
[using-go-templating-language]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/using-go-templating-language"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -16,6 +16,22 @@ labels:
|
||||
- oss
|
||||
title: Using Go's templating language
|
||||
weight: 100
|
||||
refs:
|
||||
create-notification-templates:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/create-notification-templates/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/create-notification-templates/
|
||||
extendeddata:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference/#extendeddata
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference/#extendeddata
|
||||
reference:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference/
|
||||
---
|
||||
|
||||
# Using Go's templating language
|
||||
@ -26,7 +42,7 @@ Before you start creating your own notification templates, we recommend that you
|
||||
|
||||
## Dot
|
||||
|
||||
In text/template there is a special cursor called dot, and is written as `.`. You can think of this cursor as a variable whose value changes depending where in the template it is used. For example, at the start of a notification template `.` refers to something called [`ExtendedData`][extendeddata] which contains a number of fields including `Alerts`, `Status`, `GroupLabels`, `CommonLabels`, `CommonAnnotations` and `ExternalURL`. However, dot might refer to something else when used in a range over a list, when used inside a `with`, or when writing feature templates to be used in other templates. You can see examples of this in [Create notification templates][create-notification-templates], and all data and functions in the [Reference][reference].
|
||||
In text/template there is a special cursor called dot, and is written as `.`. You can think of this cursor as a variable whose value changes depending where in the template it is used. For example, at the start of a notification template `.` refers to something called [`ExtendedData`](ref:extendeddata) which contains a number of fields including `Alerts`, `Status`, `GroupLabels`, `CommonLabels`, `CommonAnnotations` and `ExternalURL`. However, dot might refer to something else when used in a range over a list, when used inside a `with`, or when writing feature templates to be used in other templates. You can see examples of this in [Create notification templates](ref:create-notification-templates), and all data and functions in the [Reference](ref:reference).
|
||||
|
||||
## Opening and closing tags
|
||||
|
||||
@ -280,14 +296,3 @@ The indentation and line breaks in the template are now absent from the text:
|
||||
alertname = "Test"
|
||||
grafana_folder = "Test alerts"
|
||||
```
|
||||
|
||||
{{% docs/reference %}}
|
||||
[create-notification-templates]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/create-notification-templates"
|
||||
[create-notification-templates]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/create-notification-templates"
|
||||
|
||||
[extendeddata]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference#extendeddata"
|
||||
[extendeddata]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference#extendeddata"
|
||||
|
||||
[reference]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/reference"
|
||||
[reference]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/reference"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -12,6 +12,47 @@ labels:
|
||||
menuTitle: Introduction
|
||||
title: Introduction to Alerting
|
||||
weight: 100
|
||||
refs:
|
||||
alertmanager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager/
|
||||
notification-policies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies/
|
||||
silences:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-silence/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-silence/
|
||||
alert-rules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/
|
||||
contact-points:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points/
|
||||
mute-timings:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/mute-timings/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/mute-timings/
|
||||
external-alertmanagers:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager/
|
||||
alert-rule-evaluation:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/rule-evaluation/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/rule-evaluation/
|
||||
---
|
||||
|
||||
# Introduction to Alerting
|
||||
@ -35,7 +76,7 @@ The following concepts are key to your understanding of how Grafana Alerting wor
|
||||
|
||||
### Alert rules
|
||||
|
||||
An [alert rule][alert-rules] consists of one or more queries and expressions that select the data you want to measure. It also contains a condition, which is the threshold that an alert rule must meet or exceed to fire.
|
||||
An [alert rule](ref:alert-rules) consists of one or more queries and expressions that select the data you want to measure. It also contains a condition, which is the threshold that an alert rule must meet or exceed to fire.
|
||||
|
||||
Add labels to uniquely identify your alert rule and configure alert routing. Labels link alert rules to notification policies, so you can easily manage which policy should handle which alerts and who gets notified.
|
||||
|
||||
@ -55,11 +96,11 @@ A rule using the PromQL expression above creates as many alert instances as the
|
||||
|
||||
{{< figure src="/static/img/docs/alerting/unified/multi-dimensional-alert.png" caption="Multiple alert instances from a single alert rule" >}}
|
||||
|
||||
[Alert rules are frequently evaluated][alert-rule-evaluation] and the state of their alert instances is updated accordingly. Only alert instances that are in a firing or resolved state are routed to notification policies to be handled.
|
||||
[Alert rules are frequently evaluated](ref:alert-rule-evaluation) and the state of their alert instances is updated accordingly. Only alert instances that are in a firing or resolved state are routed to notification policies to be handled.
|
||||
|
||||
### Notification policies
|
||||
|
||||
[Notification policies][notification-policies] group alerts and then route them to contact points. They determine when notifications are sent, and how often notifications should be repeated.
|
||||
[Notification policies](ref:notification-policies) group alerts and then route them to contact points. They determine when notifications are sent, and how often notifications should be repeated.
|
||||
|
||||
Alert instances are matched to notification policies using label matchers. This provides a flexible way to organize and route alerts to different receivers.
|
||||
|
||||
@ -69,13 +110,13 @@ Each policy consists of a set of label matchers (0 or more) that specify which a
|
||||
|
||||
### Contact points
|
||||
|
||||
[Contact points][contact-points] determine where notifications are sent. For example, you might have a contact point that sends notifications to an email address, to Slack, to an incident management system (IRM) such as Grafana OnCall or Pagerduty, or to a webhook.
|
||||
[Contact points](ref:contact-points) determine where notifications are sent. For example, you might have a contact point that sends notifications to an email address, to Slack, to an incident management system (IRM) such as Grafana OnCall or Pagerduty, or to a webhook.
|
||||
|
||||
Notifications sent from contact points are customizable with notification templates, which can be shared between contact points.
|
||||
|
||||
### Silences and mute timings
|
||||
|
||||
[Silences][silences] and [mute timings][mute-timings] allow you to pause notifications for specific alerts or even entire notification policies. Use a silence to pause notifications on an ad-hoc basis, such as during a maintenance window; and use mute timings to pause notifications at regular intervals, such as evenings and weekends.
|
||||
[Silences](ref:silences) and [mute timings](ref:mute-timings) allow you to pause notifications for specific alerts or even entire notification policies. Use a silence to pause notifications on an ad-hoc basis, such as during a maintenance window; and use mute timings to pause notifications at regular intervals, such as evenings and weekends.
|
||||
|
||||
### Architecture
|
||||
|
||||
@ -88,7 +129,7 @@ Prometheus-based alerting systems have two main components:
|
||||
|
||||
Grafana doesn’t use Prometheus as its default alert generator because Grafana Alerting needs to work with many other data sources in addition to Prometheus.
|
||||
|
||||
However, Grafana can also use Prometheus as an alert generator as well as external Alertmanagers. For more information about how to use distinct alerting systems, refer to the [Grafana alert rule types][alert-rules].
|
||||
However, Grafana can also use Prometheus as an alert generator as well as external Alertmanagers. For more information about how to use distinct alerting systems, refer to the [Grafana alert rule types](ref:alert-rules).
|
||||
|
||||
## Design your Alerting system
|
||||
|
||||
@ -121,29 +162,3 @@ Here are some tips on how to create an effective alert management set up for you
|
||||
- Continually tune your alert rules to review effectiveness. Remove alert rules to avoid duplication or ineffective alerts.
|
||||
- Think carefully about priority and severity levels.
|
||||
- Continually review your thresholds and evaluation rules.
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alert-rules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules"
|
||||
[alert-rules]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules"
|
||||
|
||||
[contact-points]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points"
|
||||
[contact-points]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points"
|
||||
|
||||
[silences]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-silence"
|
||||
[silences]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-silence"
|
||||
|
||||
[mute-timings]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/mute-timings"
|
||||
[mute-timings]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/mute-timings"
|
||||
|
||||
[alertmanager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager"
|
||||
[alertmanager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager"
|
||||
|
||||
[alert-rule-evaluation]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation"
|
||||
[alert-rule-evaluation]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation"
|
||||
|
||||
[external-alertmanagers]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager"
|
||||
[external-alertmanagers]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager"
|
||||
[notification-policies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies"
|
||||
[notification-policies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -14,6 +14,12 @@ labels:
|
||||
- oss
|
||||
title: Alert rule evaluation
|
||||
weight: 108
|
||||
refs:
|
||||
alerts-state-health:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/
|
||||
---
|
||||
|
||||
# Alert rule evaluation
|
||||
@ -87,11 +93,4 @@ An alert instance is resolved when it transitions from the `Firing` to the `Norm
|
||||
| 03:00 (sixth evaluation) | Not met | Normal <sup>Resolved \*</sup> | 120s |
|
||||
| 03:30 (seventh evaluation) | Not met | Normal | 150s |
|
||||
|
||||
To learn more about the state changes of alert rules and alert instances, refer to [State and health of alert rules][alerts-state-health].
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alerts-state-health]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health"
|
||||
[alerts-state-health]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
To learn more about the state changes of alert rules and alert instances, refer to [State and health of alert rules](ref:alerts-state-health).
|
||||
|
@ -18,6 +18,22 @@ labels:
|
||||
- oss
|
||||
title: State and health of alerts
|
||||
weight: 109
|
||||
refs:
|
||||
pending-period:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/#pending-period
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/#pending-period
|
||||
no-data-and-error-handling:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/create-grafana-managed-rule/#configure-no-data-and-error-handling
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/create-grafana-managed-rule/#configure-no-data-and-error-handling
|
||||
notifications:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/
|
||||
---
|
||||
|
||||
# State and health of alerts
|
||||
@ -31,8 +47,8 @@ An alert instance can be in either of the following states:
|
||||
| State | Description |
|
||||
| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| **Normal** | The state of an alert when the condition (threshold) is not met. |
|
||||
| **Pending** | The state of an alert that has breached the threshold but for less than the [pending period.][pending-period] |
|
||||
| **Alerting** | The state of an alert that has breached the threshold for longer than the [pending period.][pending-period] |
|
||||
| **Pending** | The state of an alert that has breached the threshold but for less than the [pending period.](ref:pending-period) |
|
||||
| **Alerting** | The state of an alert that has breached the threshold for longer than the [pending period.](ref:pending-period) |
|
||||
| **NoData** | The state of an alert whose query returns no data or all values are null. You can [change the default behavior.](/docs/grafana/latest/alerting/alerting-rules/create-grafana-managed-rule/#configure-no-data-and-error-handling) |
|
||||
| **Error** | The state of an alert when an error or timeout occurred evaluating the alert rule. You can [change the default behavior.](/docs/grafana/latest/alerting/alerting-rules/create-grafana-managed-rule/#configure-no-data-and-error-handling) |
|
||||
|
||||
@ -40,7 +56,7 @@ An alert instance can be in either of the following states:
|
||||
|
||||
### Notifications
|
||||
|
||||
Alert instances will be routed for [notifications][notifications] when they are in the `Alerting` state or have been `Resolved`, transitioning from `Alerting` to `Normal` state.
|
||||
Alert instances will be routed for [notifications](ref:notifications) when they are in the `Alerting` state or have been `Resolved`, transitioning from `Alerting` to `Normal` state.
|
||||
|
||||
{{< figure src="/media/docs/alerting/alert-rule-evaluation-overview-statediagram-v2.png" max-width="750px" >}}
|
||||
|
||||
@ -54,7 +70,7 @@ Stale alert instances that are in the **Alerting**, **NoData**, or **Error** sta
|
||||
|
||||
The "Keep Last State" option helps mitigate temporary data source issues, preventing alerts from unintentionally firing, resolving, and re-firing.
|
||||
|
||||
In [Configure no data and error handling,][no-data-and-error-handling] you can decide to keep the last state of the alert instance when a `NoData` and/or `Error` state is encountered. Just like normal evaluation, the alert instance transitions from `Pending` to `Alerting` after the pending period has elapsed.
|
||||
In [Configure no data and error handling,](ref:no-data-and-error-handling) you can decide to keep the last state of the alert instance when a `NoData` and/or `Error` state is encountered. Just like normal evaluation, the alert instance transitions from `Pending` to `Alerting` after the pending period has elapsed.
|
||||
|
||||
{{< figure src="/media/docs/alerting/alert-rule-configure-no-data-and-error.png" max-width="500px" >}}
|
||||
|
||||
@ -91,16 +107,3 @@ An alert rule can have one of the following health statuses:
|
||||
| **Error** | An error occurred when evaluating an alerting rule. |
|
||||
| **NoData** | The absence of data in at least one time series returned during a rule evaluation. |
|
||||
| **{status}, KeepLast** | The rule would have received another status but was configured to keep the last state of the alert rule. |
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[notifications]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications"
|
||||
[notifications]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications"
|
||||
|
||||
[pending-period]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation#pending-period"
|
||||
[pending-period]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation#pending-period"
|
||||
|
||||
[no-data-and-error-handling]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/create-grafana-managed-rule#configure-no-data-and-error-handling"
|
||||
[no-data-and-error-handling]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/create-grafana-managed-rule#configure-no-data-and-error-handling"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
|
@ -17,6 +17,40 @@ labels:
|
||||
- oss
|
||||
title: Alert rules
|
||||
weight: 100
|
||||
refs:
|
||||
queries-and-conditions:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions/
|
||||
recorded-queries:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/recorded-queries/
|
||||
notification-images:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/images-in-notifications/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/images-in-notifications/
|
||||
alert-manager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager/
|
||||
create-recording-rules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/create-mimir-loki-managed-recording-rule/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/create-mimir-loki-managed-recording-rule/
|
||||
expression-queries:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions/#expression-queries
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions/#expression-queries
|
||||
alert-rule-evaluation:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/rule-evaluation/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/rule-evaluation/
|
||||
---
|
||||
|
||||
# Alert rules
|
||||
@ -25,7 +59,7 @@ An alert rule is a set of evaluation criteria for when an alert rule should fire
|
||||
|
||||
- Queries and expressions that select the data set to evaluate.
|
||||
- A condition (the threshold) that the query must meet or exceed to trigger the alert instance.
|
||||
- An interval that specifies the frequency of [alert rule evaluation][alert-rule-evaluation] and a duration indicating how long the condition must be met to trigger the alert instance.
|
||||
- An interval that specifies the frequency of [alert rule evaluation](ref:alert-rule-evaluation) and a duration indicating how long the condition must be met to trigger the alert instance.
|
||||
- Other customizable options, for example, setting what should happen in the absence of data, notification messages, and more.
|
||||
|
||||
Grafana supports two different alert rule types: Grafana-managed alert rules and data source-managed alert rules.
|
||||
@ -34,7 +68,7 @@ Grafana supports two different alert rule types: Grafana-managed alert rules and
|
||||
|
||||
Grafana-managed alert rules are the most flexible alert rule type. They allow you to create alerts that can act on data from any of the [supported data sources](#supported-data-sources), and use multiple data sources in a single alert rule.
|
||||
|
||||
Additionally, you can also add [expressions to transform your data][expression-queries], set custom alert conditions, and include [images in alert notifications][notification-images].
|
||||
Additionally, you can also add [expressions to transform your data](ref:expression-queries), set custom alert conditions, and include [images in alert notifications](ref:notification-images).
|
||||
|
||||
{{< figure src="/media/docs/alerting/grafana-managed-alerting-architecture.png" max-width="750px" caption="How Grafana-managed alerting works by default" >}}
|
||||
|
||||
@ -42,7 +76,7 @@ Additionally, you can also add [expressions to transform your data][expression-q
|
||||
|
||||
1. Alert rules are evaluated by the Alert Rule Evaluation Engine from within Grafana.
|
||||
|
||||
1. Firing and resolved alert instances are delivered to the internal Grafana [Alertmanager][alert-manager] which handles notifications.
|
||||
1. Firing and resolved alert instances are delivered to the internal Grafana [Alertmanager](ref:alert-manager) which handles notifications.
|
||||
|
||||
### Supported data sources
|
||||
|
||||
@ -61,52 +95,26 @@ They are only supported for Prometheus-based or Loki data sources with the Ruler
|
||||
1. Alert rules are created and stored within the data source itself.
|
||||
1. Alert rules can only query Prometheus-based data. It can use either queries or [recording rules](#recording-rules).
|
||||
1. Alert rules are evaluated by the Alert Rule Evaluation Engine.
|
||||
1. Firing and resolved alert instances are delivered to the configured [Alertmanager][alert-manager] which handles notifications.
|
||||
1. Firing and resolved alert instances are delivered to the configured [Alertmanager](ref:alert-manager) which handles notifications.
|
||||
|
||||
### Recording rules
|
||||
|
||||
A recording rule allows you to pre-compute frequently needed or computationally expensive expressions and save their result as a new set of time series. This is useful if you want to run alerts on aggregated data or if you have dashboards that query computationally expensive expressions repeatedly.
|
||||
|
||||
Querying this new time series is faster, especially for dashboards since they query the same expression every time the dashboards refresh. For more information, refer to [Create recording rules][create-recording-rules].
|
||||
Querying this new time series is faster, especially for dashboards since they query the same expression every time the dashboards refresh. For more information, refer to [Create recording rules](ref:create-recording-rules).
|
||||
|
||||
Alternatively, Grafana Enterprise and Grafana Cloud offer [recorded queries][recorded-queries] that can be executed against any data source.
|
||||
Alternatively, Grafana Enterprise and Grafana Cloud offer [recorded queries](ref:recorded-queries) that can be executed against any data source.
|
||||
|
||||
## Comparison between alert rule types
|
||||
|
||||
When choosing which alert rule type to use, consider the following comparison between Grafana-managed and data source-managed alert rules.
|
||||
|
||||
| <div style="width:200px">Feature</div> | <div style="width:200px">Grafana-managed alert rule</div> | <div style="width:200px">Data source-managed alert rule |
|
||||
| --------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
|
||||
| Create alert rules<wbr /> based any [supported data sources](#supported-data-sources) | Yes | No. Only Prometheus-based or Loki data sources. |
|
||||
| Mix and match data sources | Yes | No |
|
||||
| Add [expressions][expression-queries] to transform<wbr /> queried data and set alert conditions | Yes | No |
|
||||
| Use [images in alert notifications][notification-images] | Yes | No |
|
||||
| Create [recording rules](#recording-rules) | No | Yes |
|
||||
| Support for [inhibition rules](https://prometheus.io/docs/alerting/latest/configuration/#inhibition-related-settings) | No | Yes |
|
||||
| Alert rule storage and evaluation | Within Grafana | Within the data source |
|
||||
| Alert delivery | Alerts are sent to either the [Grafana Alertmanager or an external Alertmanager][alert-manager]. | Alerts from the data source are sent to the Alertmanager configured in the data source. |
|
||||
| Scalability | More resource-intensive as it depends on the Grafana instance and its database. It only scales vertically. | Evaluate and generate alerts from the data source. A distributed architecture allows for horizontal scaling. |
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alert-manager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/alertmanager"
|
||||
[alert-manager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/alertmanager"
|
||||
|
||||
[create-recording-rules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/create-mimir-loki-managed-recording-rule"
|
||||
[create-recording-rules]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/create-mimir-loki-managed-recording-rule"
|
||||
|
||||
[alert-rule-evaluation]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation"
|
||||
[alert-rule-evaluation]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation"
|
||||
|
||||
[expression-queries]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions#expression-queries"
|
||||
[expression-queries]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions#expression-queries"
|
||||
|
||||
[queries-and-conditions]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/queries-conditions"
|
||||
[queries-and-conditions]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/queries-conditions"
|
||||
|
||||
[notification-images]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/images-in-notifications"
|
||||
[notification-images]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/images-in-notifications"
|
||||
|
||||
[recorded-queries]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/recorded-queries"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
| <div style="width:200px">Feature</div> | <div style="width:200px">Grafana-managed alert rule</div> | <div style="width:200px">Data source-managed alert rule |
|
||||
| ------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| Create alert rules<wbr /> based on data from any of the supported data sources | Yes | No. You can only create alert rules that are based on Prometheus-based data. |
|
||||
| Mix and match data sources | Yes | No |
|
||||
| Includes support for recording rules | No | Yes |
|
||||
| Add expressions to transform<wbr /> your data and set alert conditions | Yes | No |
|
||||
| Use images in alert notifications | Yes | No |
|
||||
| Scaling | More resource intensive, depend on the database, and are likely to suffer from transient errors. They only scale vertically. | Store alert rules within the data source itself and allow for “infinite” scaling. Generate and send alert notifications from the location of your data. |
|
||||
| Alert rule evaluation and delivery | Alert rule evaluation and delivery is done from within Grafana, using an external Alertmanager; or both. | Alert rule evaluation and alert delivery is distributed, meaning there is no single point of failure. |
|
||||
|
@ -20,6 +20,12 @@ labels:
|
||||
- oss
|
||||
title: Labels and annotations
|
||||
weight: 105
|
||||
refs:
|
||||
variables-label-annotation:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/templating-labels-annotations/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/templating-labels-annotations/
|
||||
---
|
||||
|
||||
# Labels and annotations
|
||||
@ -141,8 +147,3 @@ Labels prefixed with `grafana_` are reserved by Grafana for special use. To stop
|
||||
Both labels and annotations have the same structure: a set of named values; however their intended uses are different. The purpose of annotations is to add additional information to existing alerts.
|
||||
|
||||
There are a number of suggested annotations in Grafana such as `description`, `summary`, `runbook_url`, `dashboardUId` and `panelId`. Like labels, annotations must have a name, and their value can contain a combination of text and template code that is evaluated when an alert is fired.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[variables-label-annotation]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/templating-labels-annotations"
|
||||
[variables-label-annotation]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/templating-labels-annotations"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -16,13 +16,24 @@ labels:
|
||||
- oss
|
||||
title: Queries and conditions
|
||||
weight: 104
|
||||
refs:
|
||||
data-source-alerting:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/#supported-data-sources
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/#supported-data-sources
|
||||
query-transform-data:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data/
|
||||
---
|
||||
|
||||
# Queries and conditions
|
||||
|
||||
In Grafana, queries play a vital role in fetching and transforming data from supported data sources, which include databases like MySQL and PostgreSQL, time series databases like Prometheus, InfluxDB and Graphite, and services like Elasticsearch, Amazon CloudWatch, Azure Monitor, and Google Cloud Monitoring.
|
||||
|
||||
For more information on supported data sources, refer to [Data sources][data-source-alerting].
|
||||
For more information on supported data sources, refer to [Data sources](ref:data-source-alerting).
|
||||
|
||||
The process of executing a query involves defining the data source, specifying the desired data to retrieve, and applying relevant filters or transformations. Query languages or syntax specific to the chosen data source are utilized for constructing these queries.
|
||||
|
||||
@ -30,7 +41,7 @@ In Alerting, you define a query to get the data you want to measure and a condit
|
||||
|
||||
An alert rule consists of one or more queries and expressions that select the data you want to measure.
|
||||
|
||||
For more information on queries and expressions, refer to [Query and transform data][query-transform-data].
|
||||
For more information on queries and expressions, refer to [Query and transform data](ref:query-transform-data).
|
||||
|
||||
## Data source queries
|
||||
|
||||
@ -206,11 +217,3 @@ When this query is used as the **condition** in an alert rule, then the non-zero
|
||||
| {Host=web1,disk=/etc} | Alerting |
|
||||
| {Host=web2,disk=/var} | Alerting |
|
||||
| {Host=web3,disk=/var} | Normal |
|
||||
|
||||
{{% docs/reference %}}
|
||||
[data-source-alerting]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules#supported-data-sources"
|
||||
[data-source-alerting]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules#supported-data-sources"
|
||||
|
||||
[query-transform-data]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/panels-visualizations/query-transform-data"
|
||||
[query-transform-data]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/visualizations/panels-visualizations/query-transform-data"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -14,6 +14,22 @@ labels:
|
||||
- oss
|
||||
title: Notifications
|
||||
weight: 110
|
||||
refs:
|
||||
templates-page:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/templates/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/templates/
|
||||
notification-policies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies/
|
||||
contact-points:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points/
|
||||
---
|
||||
|
||||
# Notifications
|
||||
@ -30,13 +46,13 @@ Grafana uses [Alertmanagers](https://grafana.com/docs/grafana/latest/alerting/fu
|
||||
|
||||
## Contact points
|
||||
|
||||
[Contact points][contact-points] contain the configuration for sending alert notifications, specifying destinations like email, Slack, OnCall, webhooks, and their notification messages. They allow the customization of notification messages and the use of notification templates.
|
||||
[Contact points](ref:contact-points) contain the configuration for sending alert notifications, specifying destinations like email, Slack, OnCall, webhooks, and their notification messages. They allow the customization of notification messages and the use of notification templates.
|
||||
|
||||
A contact point is a list of integrations, each sending a message to a specific destination. You can configure them via notification policies or alert rules.
|
||||
|
||||
## Notification policies
|
||||
|
||||
[Notification policies][notification-policies] control when and where notifications are sent. A notification policy can choose to send all alerts together in the same notification, send alerts in grouped notifications based on a set of labels, or send alerts as separate notifications. You can configure each notification policy to control how often notifications should be sent as well as having one or more mute timings to inhibit notifications at certain times of the day and on certain days of the week.
|
||||
[Notification policies](ref:notification-policies) control when and where notifications are sent. A notification policy can choose to send all alerts together in the same notification, send alerts in grouped notifications based on a set of labels, or send alerts as separate notifications. You can configure each notification policy to control how often notifications should be sent as well as having one or more mute timings to inhibit notifications at certain times of the day and on certain days of the week.
|
||||
|
||||
Notification policies are organized in a tree structure where at the root of the tree there is a notification policy called the default policy. There can be only one default policy and the default policy cannot be deleted.
|
||||
|
||||
@ -50,7 +66,7 @@ All alerts, irrespective of their labels, match the default policy. However, whe
|
||||
|
||||
## Notification templates
|
||||
|
||||
You can customize notifications with [templates][templates-page]. For example, templates can be used to change the subject and message of an email, or the title and message of notifications sent to Slack.
|
||||
You can customize notifications with [templates](ref:templates-page). For example, templates can be used to change the subject and message of an email, or the title and message of notifications sent to Slack.
|
||||
|
||||
Templates are not limited to an individual integration or contact point, but instead can be used in a number of integrations in the same contact point and even integrations across different contact points. For example, a Grafana user can create a template called `custom_subject_or_title` and use it for both templating subjects in emails and titles of Slack messages without having to create two separate templates.
|
||||
|
||||
@ -59,14 +75,3 @@ All notifications templates are written in [Go's templating language](https://pk
|
||||
## Silences
|
||||
|
||||
You can use [silences](https://grafana.com/docs/grafana/latest/alerting/manage-notifications/create-silence/) to mute notifications from one or more firing rules. Silences do not stop alerts from firing or being resolved, or hide firing alerts in the user interface. A silence lasts as long as its duration, which can be configured in minutes, hours, days, months, or years.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[notification-policies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/notification-policies"
|
||||
[notification-policies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/notification-policies"
|
||||
|
||||
[contact-points]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/contact-points"
|
||||
[contact-points]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/contact-points"
|
||||
|
||||
[templates-page]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/notifications/templates/"
|
||||
[templates-page]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/notifications/templates/"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -12,6 +12,12 @@ labels:
|
||||
- oss
|
||||
title: Alertmanager
|
||||
weight: 111
|
||||
refs:
|
||||
configure-alertmanager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager/
|
||||
---
|
||||
|
||||
# Alertmanager
|
||||
@ -34,13 +40,8 @@ In Grafana, you can use the Cloud Alertmanager, Grafana Alertmanager, or an exte
|
||||
|
||||
- **External Alertmanager** can receive all your Grafana, Loki, Mimir, and Prometheus alerts. External Alertmanagers can be configured and administered from within Grafana itself.
|
||||
|
||||
Here are two examples of when you may want to [add your own external Alertmanager][configure-alertmanager] and send your alerts there instead of the Grafana Alertmanager:
|
||||
Here are two examples of when you may want to [add your own external Alertmanager](ref:configure-alertmanager) and send your alerts there instead of the Grafana Alertmanager:
|
||||
|
||||
1. You may already have Alertmanagers on-premises in your own Cloud infrastructure that you have set up and still want to use, because you have other alert generators, such as Prometheus.
|
||||
|
||||
2. You want to use both Prometheus on-premises and hosted Grafana to send alerts to the same Alertmanager that runs in your Cloud infrastructure.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[configure-alertmanager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager"
|
||||
[configure-alertmanager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -17,6 +17,12 @@ labels:
|
||||
- oss
|
||||
title: Notification policies
|
||||
weight: 113
|
||||
refs:
|
||||
labels-and-label-matchers:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label/#how-label-matching-works
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label/#how-label-matching-works
|
||||
---
|
||||
|
||||
# Notification policies
|
||||
@ -31,7 +37,7 @@ Notification policies are _not_ a list, but rather are structured according to a
|
||||
|
||||
Each policy consists of a set of label matchers (0 or more) that specify which labels they are or aren't interested in handling.
|
||||
|
||||
For more information on label matching, refer to [how label matching works][labels-and-label-matchers].
|
||||
For more information on label matching, refer to [how label matching works](ref:labels-and-label-matchers).
|
||||
|
||||
{{% admonition type="note" %}}
|
||||
If you haven't configured any label matchers for your notification policy, your notification policy matches _all_ alert instances. This may prevent child policies from being evaluated unless you have enabled **Continue matching siblings** on the notification policy.
|
||||
@ -129,8 +135,3 @@ Once the first notification has been sent for a new group of alerts, the Group i
|
||||
Repeat interval decides how often notifications are repeated if the group has not changed since the last notification. You can think of these as reminders that some alerts are still firing. Repeat interval is closely related to Group interval, which means your Repeat interval must not only be greater than or equal to Group interval, but also must be a multiple of Group interval. If Repeat interval is not a multiple of Group interval it is coerced into one. For example, if your Group interval is 5 minutes, and your Repeat interval is 9 minutes, the Repeat interval is rounded up to the nearest multiple of 5 which is 10 minutes.
|
||||
|
||||
**Default** 4 hours
|
||||
|
||||
{{% docs/reference %}}
|
||||
[labels-and-label-matchers]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/annotation-label#how-label-matching-works"
|
||||
[labels-and-label-matchers]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/annotation-label#how-label-matching-works"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -18,6 +18,12 @@ labels:
|
||||
- oss
|
||||
title: Templates
|
||||
weight: 114
|
||||
refs:
|
||||
variables-label-annotation:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/templating-labels-annotations/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/templating-labels-annotations/
|
||||
---
|
||||
|
||||
# Templates
|
||||
@ -68,7 +74,7 @@ Templating can be applied by using variables and functions. These variables can
|
||||
In Grafana templating, the $ and . symbols are used to reference variables and their properties. You can reference variables directly in your alert rule definitions using the $ symbol followed by the variable name. Similarly, you can access properties of variables using the dot (.) notation within alert rule definitions.
|
||||
{{</admonition>}}
|
||||
|
||||
Here are some commonly used built-in [variables][variables-label-annotation] to interact with the name and value of labels in Grafana alerting:
|
||||
Here are some commonly used built-in [variables](ref:variables-label-annotation) to interact with the name and value of labels in Grafana alerting:
|
||||
|
||||
- The `$labels` variable, which contains all labels from the query.
|
||||
|
||||
@ -147,13 +153,8 @@ This is the message you would receive in your contact point:
|
||||
1 resolved alert(s)
|
||||
- The web server web1 has been responding to 5% of HTTP requests with 5xx errors for the last 5 minutes
|
||||
|
||||
Once the template is created, you need to make reference to it in your **Contact point** (in the Optional [contact point] settings) .
|
||||
Once the template is created, you need to make reference to it in your **Contact point** (in the Optional `[contact point]` settings) .
|
||||
|
||||
{{<admonition type="note">}}
|
||||
It's not recommended to include individual alert information within notification templates. Instead, it's more effective to incorporate such details within the rule using labels and annotations.
|
||||
{{</admonition>}}
|
||||
|
||||
{{% docs/reference %}}
|
||||
[variables-label-annotation]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/templating-labels-annotations"
|
||||
[variables-label-annotation]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/templating-labels-annotations"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -17,15 +17,36 @@ labels:
|
||||
- oss
|
||||
title: View alert state and history
|
||||
weight: 420
|
||||
refs:
|
||||
alert-rule-state:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-rule-state
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-rule-state
|
||||
alert-rule-evaluation:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/
|
||||
alert-instance-state:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-instance-state
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-instance-state
|
||||
alert-rule-health:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-rule-health
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health/#alert-rule-health
|
||||
---
|
||||
|
||||
# View alert state and history
|
||||
|
||||
An alert rule and its corresponding alert instances can transition through distinct states during their [evaluation][alert-rule-evaluation]. There are three key components that helps us understand the behavior of our alerts:
|
||||
An alert rule and its corresponding alert instances can transition through distinct states during their [evaluation](ref:alert-rule-evaluation). There are three key components that helps us understand the behavior of our alerts:
|
||||
|
||||
- [Alert Instance State][alert-instance-state]: Refers to the state of the individual alert instances.
|
||||
- [Alert Rule State][alert-rule-state]: Determined by the "worst state" among its alert instances.
|
||||
- [Alert Rule Health][alert-rule-health]: Indicates the status in cases of `Error` or `NoData` events.
|
||||
- [Alert Instance State](ref:alert-instance-state): Refers to the state of the individual alert instances.
|
||||
- [Alert Rule State](ref:alert-rule-state): Determined by the "worst state" among its alert instances.
|
||||
- [Alert Rule Health](ref:alert-rule-health): Indicates the status in cases of `Error` or `NoData` events.
|
||||
|
||||
To view the state and health of your alert rules:
|
||||
|
||||
@ -64,19 +85,3 @@ To access the State history view, complete the following steps.
|
||||
1. Click the labels to filter and narrow down the results.
|
||||
|
||||
{{< figure src="/media/docs/alerting/state-history.png" max-width="750px" >}}
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alert-rule-evaluation]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation"
|
||||
[alert-rule-evaluation]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation"
|
||||
|
||||
[alert-rule-state]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-rule-state"
|
||||
[alert-rule-state]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-rule-state"
|
||||
|
||||
[alert-instance-state]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-instance-state"
|
||||
[alert-instance-state]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-instance-state"
|
||||
|
||||
[alert-rule-health]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-rule-health"
|
||||
[alert-rule-health]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rule-evaluation/state-and-health#alert-rule-health"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
|
@ -29,9 +29,9 @@ Identify which metrics are critical to your monitoring system (i.e. Grafana) and
|
||||
|
||||
You can use meta-monitoring metrics to understand the health of your alerting system in the following ways:
|
||||
|
||||
1. [Optional] Create a dashboard in Grafana that uses this metric in a panel (just like you would for any other kind of metric).
|
||||
2. [Optional] Create an alert rule in Grafana that checks this metric regularly (just like you would do for any other kind of alert rule).
|
||||
3. [Optional] Use the Explore module in Grafana.
|
||||
1. Optional: Create a dashboard in Grafana that uses this metric in a panel (just like you would for any other kind of metric).
|
||||
2. Optional: Create an alert rule in Grafana that checks this metric regularly (just like you would do for any other kind of alert rule).
|
||||
3. Optional: Use the Explore module in Grafana.
|
||||
|
||||
## Metrics for Grafana-managed alerts
|
||||
|
||||
|
@ -9,6 +9,33 @@ labels:
|
||||
menuTitle: Set up
|
||||
title: Set up Alerting
|
||||
weight: 110
|
||||
refs:
|
||||
terraform-provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
configure-high-availability:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-high-availability/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-high-availability/
|
||||
configure-alertmanager:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager/
|
||||
data-source-management:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/data-source-management/
|
||||
data-source-alerting:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules/#supported-data-sources
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules/#supported-data-sources
|
||||
file-provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning/
|
||||
---
|
||||
|
||||
# Set up Alerting
|
||||
@ -21,8 +48,8 @@ These are set-up instructions for Grafana Alerting Open Source.
|
||||
|
||||
## Before you begin
|
||||
|
||||
- Configure your [data sources][data-source-management]
|
||||
- Check which data sources are compatible with and supported by [Grafana Alerting][data-source-alerting]
|
||||
- Configure your [data sources](ref:data-source-management)
|
||||
- Check which data sources are compatible with and supported by [Grafana Alerting](ref:data-source-alerting)
|
||||
|
||||
Watch this short video to get started, or follow the [written tutorial](http://grafana.com/tutorials/alerting-get-started/).
|
||||
|
||||
@ -40,17 +67,17 @@ To set up Alerting, you need to:
|
||||
|
||||
- Check the default contact point and update the email address
|
||||
|
||||
- [Optional] Add new contact points and integrations
|
||||
- Optional: Add new contact points and integrations
|
||||
|
||||
1. Configure notification policies
|
||||
|
||||
- Check the default notification policy
|
||||
|
||||
- [Optional] Add additional nested policies
|
||||
- Optional: Add additional nested policies
|
||||
|
||||
- [Optional] Add labels and label matchers to control alert routing
|
||||
- Optional: Add labels and label matchers to control alert routing
|
||||
|
||||
1. [Optional] Integrate with [Grafana OnCall](/docs/oncall/latest/integrations/grafana-alerting)
|
||||
1. Optional: Integrate with [Grafana OnCall](/docs/oncall/latest/integrations/grafana-alerting)
|
||||
|
||||
## Advanced set up options
|
||||
|
||||
@ -58,25 +85,7 @@ Grafana Alerting supports many additional configuration options, from configurin
|
||||
|
||||
The following topics provide you with advanced configuration options for Grafana Alerting.
|
||||
|
||||
- [Provision alert rules using file provisioning][file-provisioning]
|
||||
- [Provision alert rules using Terraform][terraform-provisioning]
|
||||
- [Add an external Alertmanager][configure-alertmanager]
|
||||
- [Configure high availability][configure-high-availability]
|
||||
|
||||
{{% docs/reference %}}
|
||||
[configure-alertmanager]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager"
|
||||
[configure-alertmanager]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-alertmanager"
|
||||
|
||||
[configure-high-availability]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-high-availability"
|
||||
[configure-high-availability]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/configure-high-availability"
|
||||
|
||||
[data-source-alerting]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/fundamentals/alert-rules#supported-data-sources"
|
||||
[data-source-alerting]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/fundamentals/alert-rules#supported-data-sources"
|
||||
|
||||
[data-source-management]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/data-source-management"
|
||||
|
||||
[file-provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning"
|
||||
|
||||
[terraform-provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
[terraform-provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
{{% /docs/reference %}}
|
||||
- [Provision alert rules using file provisioning](ref:file-provisioning)
|
||||
- [Provision alert rules using Terraform](ref:terraform-provisioning)
|
||||
- [Add an external Alertmanager](ref:configure-alertmanager)
|
||||
- [Configure high availability](ref:configure-high-availability)
|
||||
|
@ -62,11 +62,11 @@ As an alternative to Memberlist, you can use Redis for high availability. This i
|
||||
database for HA and cannot support the meshing of all Grafana servers.
|
||||
|
||||
1. Make sure you have a Redis server that supports pub/sub. If you use a proxy in front of your Redis cluster, make sure the proxy supports pub/sub.
|
||||
1. In your custom configuration file ($WORKING_DIR/conf/custom.ini), go to the [unified_alerting] section.
|
||||
1. In your custom configuration file ($WORKING_DIR/conf/custom.ini), go to the `[unified_alerting]` section.
|
||||
1. Set `ha_redis_address` to the Redis server address Grafana should connect to.
|
||||
1. [Optional] Set the username and password if authentication is enabled on the Redis server using `ha_redis_username` and `ha_redis_password`.
|
||||
1. [Optional] Set `ha_redis_prefix` to something unique if you plan to share the Redis server with multiple Grafana instances.
|
||||
1. [Optional] Set `ha_redis_tls_enabled` to `true` and configure the corresponding `ha_redis_tls_*` fields to secure communications between Grafana and Redis with Transport Layer Security (TLS).
|
||||
1. Optional: Set the username and password if authentication is enabled on the Redis server using `ha_redis_username` and `ha_redis_password`.
|
||||
1. Optional: Set `ha_redis_prefix` to something unique if you plan to share the Redis server with multiple Grafana instances.
|
||||
1. Optional: Set `ha_redis_tls_enabled` to `true` and configure the corresponding `ha_redis_tls_*` fields to secure communications between Grafana and Redis with Transport Layer Security (TLS).
|
||||
|
||||
The following metrics can be used for meta monitoring, exposed by the `/metrics` endpoint in Grafana:
|
||||
|
||||
|
@ -14,6 +14,33 @@ labels:
|
||||
- oss
|
||||
title: Provision Alerting resources
|
||||
weight: 300
|
||||
refs:
|
||||
alerting_export_http:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-api-endpoints
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-api-endpoints
|
||||
alerting_file_provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning/
|
||||
alerting_http_provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
alerting_export:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/
|
||||
alerting_tf_provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/provisioning/
|
||||
---
|
||||
|
||||
# Provision Alerting resources
|
||||
@ -28,7 +55,7 @@ You cannot edit imported alerting resources in the Grafana UI in the same way as
|
||||
|
||||
Choose from the options below to import (or provision) your Grafana Alerting resources.
|
||||
|
||||
1. [Use configuration files to provision your alerting resources][alerting_file_provisioning], such as alert rules and contact points, through files on disk.
|
||||
1. [Use configuration files to provision your alerting resources](ref:alerting_file_provisioning), such as alert rules and contact points, through files on disk.
|
||||
|
||||
{{< admonition type="note" >}}
|
||||
|
||||
@ -36,9 +63,9 @@ Choose from the options below to import (or provision) your Grafana Alerting res
|
||||
- Provisioning with configuration files is not available in Grafana Cloud.
|
||||
{{< /admonition >}}
|
||||
|
||||
1. Use [Terraform to provision alerting resources][alerting_tf_provisioning].
|
||||
1. Use [Terraform to provision alerting resources](ref:alerting_tf_provisioning).
|
||||
|
||||
1. Use the [Alerting provisioning HTTP API][alerting_http_provisioning] to manage alerting resources.
|
||||
1. Use the [Alerting provisioning HTTP API](ref:alerting_http_provisioning) to manage alerting resources.
|
||||
|
||||
{{< admonition type="note" >}}
|
||||
The JSON output from the majority of Alerting HTTP endpoints isn't compatible for provisioning via configuration files.
|
||||
@ -50,7 +77,7 @@ Choose from the options below to import (or provision) your Grafana Alerting res
|
||||
|
||||
You can export both manually created and provisioned alerting resources. You can also edit and export an alert rule without applying the changes.
|
||||
|
||||
For detailed instructions on the various export options, refer to [Export alerting resources][alerting_export].
|
||||
For detailed instructions on the various export options, refer to [Export alerting resources](ref:alerting_export).
|
||||
|
||||
## View provisioned alerting resources
|
||||
|
||||
@ -61,19 +88,3 @@ To view your provisioned resources in Grafana, complete the following steps.
|
||||
1. Click an alerting resource folder, for example, Alert rules.
|
||||
|
||||
Provisioned resources are labeled **Provisioned**, so that it is clear that they were not created manually.
|
||||
|
||||
{{% docs/reference %}}
|
||||
[alerting_tf_provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
[alerting_tf_provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
[alerting_http_provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
[alerting_http_provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
[alerting_export]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources"
|
||||
[alerting_export]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources"
|
||||
|
||||
[alerting_export_http]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-api-endpoints"
|
||||
[alerting_export_http]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-api-endpoints"
|
||||
|
||||
[alerting_file_provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning"
|
||||
|
||||
[provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/provisioning"
|
||||
{{% /docs/reference %}}
|
||||
|
@ -15,6 +15,88 @@ labels:
|
||||
- oss
|
||||
title: Export alerting resources
|
||||
weight: 300
|
||||
refs:
|
||||
alerting_file_provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning/
|
||||
export_mute_timings:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-mute-timings-exportspan-export-all-mute-timings-in-provisioning-file-format-_routegetmutetimingsexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-mute-timings-exportspan-export-all-mute-timings-in-provisioning-file-format-_routegetmutetimingsexport_
|
||||
export_rules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rules-exportspan-export-all-alert-rules-in-provisioning-file-format-_routegetalertrulesexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rules-exportspan-export-all-alert-rules-in-provisioning-file-format-_routegetalertrulesexport_
|
||||
alerting_file_provisioning_template:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning/#import-templates
|
||||
export_rule_group:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rule-group-exportspan-export-an-alert-rule-group-in-provisioning-file-format-_routegetalertrulegroupexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rule-group-exportspan-export-an-alert-rule-group-in-provisioning-file-format-_routegetalertrulegroupexport_
|
||||
alerting_tf_provisioning_template:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning/#import-contact-points-and-templates
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning/#import-contact-points-and-templates
|
||||
export_mute_timing:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-mute-timing-exportspan-export-a-mute-timing-in-provisioning-file-format-_routegetmutetimingexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-mute-timing-exportspan-export-a-mute-timing-in-provisioning-file-format-_routegetmutetimingexport_
|
||||
alerting_http_mutetimings:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#mute-timings
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/#mute-timings
|
||||
alerting_http_alertrules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#alert-rules
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/#alert-rules
|
||||
alerting_tf_provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning/
|
||||
export_rule:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rule-exportspan-export-an-alert-rule-in-provisioning-file-format-_routegetalertruleexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-alert-rule-exportspan-export-an-alert-rule-in-provisioning-file-format-_routegetalertruleexport_
|
||||
alerting_http_templates:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#templates
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/#templates
|
||||
alerting_http_contactpoints:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#contact-points
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/#contact-points
|
||||
alerting_http_notificationpolicies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#notification-policies
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/#notification-policies
|
||||
export_notifications:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-policy-tree-exportspan-export-the-notification-policy-tree-in-provisioning-file-format-_routegetpolicytreeexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-policy-tree-exportspan-export-the-notification-policy-tree-in-provisioning-file-format-_routegetpolicytreeexport_
|
||||
alerting_http_provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
export_contacts:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-contactpoints-exportspan-export-all-contact-points-in-provisioning-file-format-_routegetcontactpointsexport_
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/#span-idroute-get-contactpoints-exportspan-export-all-contact-points-in-provisioning-file-format-_routegetcontactpointsexport_
|
||||
---
|
||||
|
||||
# Export alerting resources
|
||||
@ -35,7 +117,7 @@ If you need to modify provisioned alerting resources in Grafana, refer to [edit
|
||||
|
||||
## Export from the Grafana UI
|
||||
|
||||
The export options listed below enable you to download resources in YAML, JSON, or Terraform format, facilitating their provisioning through [configuration files][alerting_file_provisioning] or [Terraform][alerting_tf_provisioning].
|
||||
The export options listed below enable you to download resources in YAML, JSON, or Terraform format, facilitating their provisioning through [configuration files](ref:alerting_file_provisioning) or [Terraform](ref:alerting_tf_provisioning).
|
||||
|
||||
### Export alert rules
|
||||
|
||||
@ -92,7 +174,7 @@ However, you can export it by manually copying the content template and title di
|
||||
1. Click **Alerts & IRM** -> **Contact points** -> **Notification templates** tab.
|
||||
1. Find the template you want to export.
|
||||
1. Copy the content and title.
|
||||
1. Adjust it for the [file provisioning format][alerting_file_provisioning_template] or [Terraform resource][alerting_tf_provisioning_template].
|
||||
1. Adjust it for the [file provisioning format](ref:alerting_file_provisioning_template) or [Terraform resource](ref:alerting_tf_provisioning_template).
|
||||
|
||||
### Export the notification policy tree
|
||||
|
||||
@ -128,86 +210,35 @@ To export mute timings from the Grafana UI, complete the following steps.
|
||||
|
||||
## HTTP Alerting API
|
||||
|
||||
You can use the [Alerting HTTP API][alerting_http_provisioning] to return existing alerting resources in JSON and import them to another Grafana instance using the same endpoint.
|
||||
You can use the [Alerting HTTP API](ref:alerting_http_provisioning) to return existing alerting resources in JSON and import them to another Grafana instance using the same endpoint.
|
||||
|
||||
| Resource | URI |
|
||||
| -------------------------------------------------------------- | ----------------------------------- |
|
||||
| [Alert rules][alerting_http_alertrules] | /api/v1/provisioning/alert-rules |
|
||||
| [Contact points][alerting_http_contactpoints] | /api/v1/provisioning/contact-points |
|
||||
| [Notification policy tree][alerting_http_notificationpolicies] | /api/v1/provisioning/policies |
|
||||
| [Mute timings][alerting_http_mutetimings] | /api/v1/provisioning/mute-timings |
|
||||
| [Templates][alerting_http_templates] | /api/v1/provisioning/templates |
|
||||
| Resource | URI |
|
||||
| ------------------------------------------------------------------ | ----------------------------------- |
|
||||
| [Alert rules](ref:alerting_http_alertrules) | /api/v1/provisioning/alert-rules |
|
||||
| [Contact points](ref:alerting_http_contactpoints) | /api/v1/provisioning/contact-points |
|
||||
| [Notification policy tree](ref:alerting_http_notificationpolicies) | /api/v1/provisioning/policies |
|
||||
| [Mute timings](ref:alerting_http_mutetimings) | /api/v1/provisioning/mute-timings |
|
||||
| [Templates](ref:alerting_http_templates) | /api/v1/provisioning/templates |
|
||||
|
||||
However, note the standard endpoints return a JSON format that is not compatible for provisioning through configuration files or Terraform, except the `/export` endpoints listed below.
|
||||
|
||||
### Export API endpoints
|
||||
|
||||
The **Alerting HTTP API** provides specific endpoints for exporting alerting resources in YAML or JSON, facilitating [provisioning via configuration files][alerting_file_provisioning], or Terraform (HCL).
|
||||
The **Alerting HTTP API** provides specific endpoints for exporting alerting resources in YAML or JSON, facilitating [provisioning via configuration files](ref:alerting_file_provisioning), or Terraform (HCL).
|
||||
|
||||
| Resource | Method / URI | Summary |
|
||||
| ------------------------ | -------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- |
|
||||
| Alert rules | GET /api/v1/provisioning/alert-rules/export | [Export all alert rules in provisioning file format.][export_rules] |
|
||||
| Alert rules | GET /api/v1/provisioning/folder/:folderUid/rule-groups/:group/export | [Export an alert rule group in provisioning file format.][export_rule_group] |
|
||||
| Alert rules | GET /api/v1/provisioning/alert-rules/:uid/export | [Export an alert rule in provisioning file format.][export_rule] |
|
||||
| Contact points | GET /api/v1/provisioning/contact-points/export | [Export all contact points in provisioning file format.][export_contacts] |
|
||||
| Notification policy tree | GET /api/v1/provisioning/policies/export | [Export the notification policy tree in provisioning file format.][export_notifications] |
|
||||
| Mute timings | GET /api/v1/provisioning/mute-timings/export | [Export all mute timings in provisioning file format.][export_mute_timings] |
|
||||
| Mute timings | GET /api/v1/provisioning/mute-timings/:name/export | [Export a mute timing in provisioning file format.][export_mute_timing] |
|
||||
| Resource | Method / URI | Summary |
|
||||
| ------------------------ | -------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
|
||||
| Alert rules | GET /api/v1/provisioning/alert-rules/export | [Export all alert rules in provisioning file format.](ref:export_rules) |
|
||||
| Alert rules | GET /api/v1/provisioning/folder/:folderUid/rule-groups/:group/export | [Export an alert rule group in provisioning file format.](ref:export_rule_group) |
|
||||
| Alert rules | GET /api/v1/provisioning/alert-rules/:uid/export | [Export an alert rule in provisioning file format.](ref:export_rule) |
|
||||
| Contact points | GET /api/v1/provisioning/contact-points/export | [Export all contact points in provisioning file format.](ref:export_contacts) |
|
||||
| Notification policy tree | GET /api/v1/provisioning/policies/export | [Export the notification policy tree in provisioning file format.](ref:export_notifications) |
|
||||
| Mute timings | GET /api/v1/provisioning/mute-timings/export | [Export all mute timings in provisioning file format.](ref:export_mute_timings) |
|
||||
| Mute timings | GET /api/v1/provisioning/mute-timings/:name/export | [Export a mute timing in provisioning file format.](ref:export_mute_timing) |
|
||||
|
||||
These endpoints accept a `download` parameter to download a file containing the exported resources.
|
||||
|
||||
<!-- prettier-ignore-start -->
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alerting_http_alertrules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#alert-rules"
|
||||
[alerting_http_alertrules]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning#alert-rules"
|
||||
|
||||
[alerting_http_contactpoints]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#contact-points"
|
||||
[alerting_http_contactpoints]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning#contact-points"
|
||||
|
||||
[alerting_http_notificationpolicies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#notification-policies"
|
||||
[alerting_http_notificationpolicies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning#notification-policies"
|
||||
|
||||
[alerting_http_mutetimings]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#mute-timings"
|
||||
[alerting_http_mutetimings]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning#mute-timings"
|
||||
|
||||
[alerting_http_templates]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#templates"
|
||||
[alerting_http_templates]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning#templates"
|
||||
|
||||
[alerting_tf_provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
[alerting_tf_provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning"
|
||||
|
||||
[alerting_tf_provisioning_template]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/terraform-provisioning#import-contact-points-and-templates"
|
||||
[alerting_tf_provisioning_template]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/terraform-provisioning#import-contact-points-and-templates"
|
||||
|
||||
[alerting_http_provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
[alerting_http_provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
|
||||
[alerting_file_provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning"
|
||||
|
||||
[alerting_file_provisioning_template]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/file-provisioning#import-templates"
|
||||
|
||||
[export_rule]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rule-exportspan-export-an-alert-rule-in-provisioning-file-format-_routegetalertruleexport_"
|
||||
[export_rule]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rule-exportspan-export-an-alert-rule-in-provisioning-file-format-_routegetalertruleexport_"
|
||||
|
||||
[export_rule_group]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rule-group-exportspan-export-an-alert-rule-group-in-provisioning-file-format-_routegetalertrulegroupexport_"
|
||||
[export_rule_group]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rule-group-exportspan-export-an-alert-rule-group-in-provisioning-file-format-_routegetalertrulegroupexport_"
|
||||
|
||||
[export_rules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rules-exportspan-export-all-alert-rules-in-provisioning-file-format-_routegetalertrulesexport_"
|
||||
[export_rules]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-alert-rules-exportspan-export-all-alert-rules-in-provisioning-file-format-_routegetalertrulesexport_"
|
||||
|
||||
[export_contacts]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-contactpoints-exportspan-export-all-contact-points-in-provisioning-file-format-_routegetcontactpointsexport_"
|
||||
[export_contacts]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-contactpoints-exportspan-export-all-contact-points-in-provisioning-file-format-_routegetcontactpointsexport_"
|
||||
|
||||
[export_mute_timing]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-mute-timing-exportspan-export-a-mute-timing-in-provisioning-file-format-_routegetmutetimingexport_"
|
||||
[export_mute_timing]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-mute-timing-exportspan-export-a-mute-timing-in-provisioning-file-format-_routegetmutetimingexport_"
|
||||
|
||||
[export_mute_timings]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-mute-timings-exportspan-export-all-mute-timings-in-provisioning-file-format-_routegetmutetimingsexport_"
|
||||
[export_mute_timings]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-mute-timings-exportspan-export-all-mute-timings-in-provisioning-file-format-_routegetmutetimingsexport_"
|
||||
|
||||
[export_notifications]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-policy-tree-exportspan-export-the-notification-policy-tree-in-provisioning-file-format-_routegetpolicytreeexport_"
|
||||
[export_notifications]: "/docs/grafana-cloud/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning#span-idroute-get-policy-tree-exportspan-export-the-notification-policy-tree-in-provisioning-file-format-_routegetpolicytreeexport_"
|
||||
{{% /docs/reference %}}
|
||||
|
||||
<!-- prettier-ignore-end -->
|
||||
|
@ -14,11 +14,46 @@ labels:
|
||||
menuTitle: Use configuration files to provision
|
||||
title: Use configuration files to provision alerting resources
|
||||
weight: 100
|
||||
refs:
|
||||
export_mute_timings:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-mute-timings
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-mute-timings
|
||||
export_alert_rules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-alert-rules
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-alert-rules
|
||||
export_contact_points:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-contact-points
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-contact-points
|
||||
provisioning_env_vars:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/provisioning/#using-environment-variables
|
||||
reload-provisioning-configurations:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/developers/http_api/admin/#reload-provisioning-configurations
|
||||
export_policies:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-the-notification-policy-tree
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-the-notification-policy-tree
|
||||
provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/provisioning/
|
||||
export_templates:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-templates
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/#export-templates
|
||||
---
|
||||
|
||||
# Use configuration files to provision alerting resources
|
||||
|
||||
Manage your alerting resources using configuration files that can be version controlled. When Grafana starts, it provisions the resources defined in your configuration files. [Provisioning][provisioning] can create, update, or delete existing resources in your Grafana instance.
|
||||
Manage your alerting resources using configuration files that can be version controlled. When Grafana starts, it provisions the resources defined in your configuration files. [Provisioning](ref:provisioning) can create, update, or delete existing resources in your Grafana instance.
|
||||
|
||||
This guide outlines the steps and references to provision alerting resources using YAML files. For a practical demo, you can clone and try [this example using Grafana OSS and Docker Compose](https://github.com/grafana/provisioning-alerting-examples/tree/main/config-files).
|
||||
|
||||
@ -40,7 +75,7 @@ Details on how to set up the files and which fields are required for each object
|
||||
Create or delete alert rules using provisioning files in your Grafana instance(s).
|
||||
|
||||
1. Find the alert rule group in Grafana.
|
||||
1. [Export][export_alert_rules] and download a provisioning file for your alert rules.
|
||||
1. [Export](ref:export_alert_rules) and download a provisioning file for your alert rules.
|
||||
1. Copy the contents into a YAML or JSON configuration file and add it to the `provisioning/alerting` directory of the Grafana instance you want to import the alerting resources to.
|
||||
|
||||
Example configuration files can be found below.
|
||||
@ -139,7 +174,7 @@ deleteRules:
|
||||
Create or delete contact points using provisioning files in your Grafana instance(s).
|
||||
|
||||
1. Find the contact point in Grafana.
|
||||
1. [Export][export_contact_points] and download a provisioning file for your contact point.
|
||||
1. [Export](ref:export_contact_points) and download a provisioning file for your contact point.
|
||||
1. Copy the contents into a YAML or JSON configuration file and add it to the `provisioning/alerting` directory of the Grafana instance you want to import the alerting resources to.
|
||||
|
||||
Example configuration files can be found below.
|
||||
@ -572,7 +607,7 @@ settings:
|
||||
Create or delete templates using provisioning files in your Grafana instance(s).
|
||||
|
||||
1. Find the notification template in Grafana.
|
||||
1. [Export][export_templates] a template by copying the template content and title.
|
||||
1. [Export](ref:export_templates) a template by copying the template content and title.
|
||||
1. Copy the contents into a YAML or JSON configuration file and add it to the `provisioning/alerting` directory of the Grafana instance you want to import the alerting resources to.
|
||||
|
||||
Example configuration files can be found below.
|
||||
@ -625,7 +660,7 @@ Since the policy tree is a single resource, provisioning it will overwrite a pol
|
||||
{{< /admonition >}}
|
||||
|
||||
1. Find the notification policy tree in Grafana.
|
||||
1. [Export][export_policies] and download a provisioning file for your notification policy tree.
|
||||
1. [Export](ref:export_policies) and download a provisioning file for your notification policy tree.
|
||||
1. Copy the contents into a YAML or JSON configuration file and add it to the `provisioning/alerting` directory of the Grafana instance you want to import the alerting resources to.
|
||||
|
||||
Example configuration files can be found below.
|
||||
@ -711,7 +746,7 @@ resetPolicies:
|
||||
Create or delete mute timings via provisioning files using provisioning files in your Grafana instance(s).
|
||||
|
||||
1. Find the mute timing in Grafana.
|
||||
1. [Export][export_mute_timings] and download a provisioning file for your mute timing.
|
||||
1. [Export](ref:export_mute_timings) and download a provisioning file for your mute timing.
|
||||
1. Copy the contents into a YAML or JSON configuration file and add it to the `provisioning/alerting` directory of the Grafana instance you want to import the alerting resources to.
|
||||
|
||||
Example configuration files can be found below.
|
||||
@ -772,7 +807,7 @@ contactPoints:
|
||||
addresses: $EMAIL
|
||||
```
|
||||
|
||||
In this example, provisioning replaces `$EMAIL` with the value of the `EMAIL` environment variable or an empty string if it is not present. For more information, refer to [Using environment variables in the Provision documentation][provisioning_env_vars].
|
||||
In this example, provisioning replaces `$EMAIL` with the value of the `EMAIL` environment variable or an empty string if it is not present. For more information, refer to [Using environment variables in the Provision documentation](ref:provisioning_env_vars).
|
||||
|
||||
In alerting resources, most properties support template variable interpolation, with a few exceptions:
|
||||
|
||||
@ -796,29 +831,5 @@ For example, when provisioning a `subject` property in a `contactPoints.receiver
|
||||
For more examples on the concept of this guide:
|
||||
|
||||
- Try provisioning alerting resources in Grafana OSS with YAML files through a demo project using [Docker Compose](https://github.com/grafana/provisioning-alerting-examples/tree/main/config-files) or [Kubernetes deployments](https://github.com/grafana/provisioning-alerting-examples/tree/main/kubernetes).
|
||||
- Review the distinct options about how Grafana provisions resources in the [Provision Grafana documentation][provisioning].
|
||||
- Review the distinct options about how Grafana provisions resources in the [Provision Grafana documentation](ref:provisioning).
|
||||
- For Helm support, review the examples provisioning alerting resources in the [Grafana Helm Chart documentation](https://github.com/grafana/helm-charts/blob/main/charts/grafana/README.md).
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[export_alert_rules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-alert-rules"
|
||||
[export_alert_rules]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-alert-rules"
|
||||
|
||||
[export_contact_points]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-contact-points"
|
||||
[export_contact_points]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-contact-points"
|
||||
|
||||
[export_templates]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-templates"
|
||||
[export_templates]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-templates"
|
||||
|
||||
[export_policies]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-the-notification-policy-tree"
|
||||
[export_policies]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-the-notification-policy-tree"
|
||||
|
||||
[export_mute_timings]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-mute-timings"
|
||||
[export_mute_timings]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources#export-mute-timings"
|
||||
|
||||
[provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/provisioning"
|
||||
[provisioning_env_vars]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/provisioning#using-environment-variables"
|
||||
|
||||
[reload-provisioning-configurations]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/developers/http_api/admin#reload-provisioning-configurations"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
|
@ -15,6 +15,59 @@ labels:
|
||||
menuTitle: Use Terraform to provision
|
||||
title: Use Terraform to provision alerting resources
|
||||
weight: 200
|
||||
refs:
|
||||
alerting_http_provisioning:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning/
|
||||
contact-points:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/
|
||||
notification-template:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/
|
||||
provision-cloud-with-terraform:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana-cloud/developer-resources/infrastructure-as-code/terraform/terraform-cloud-stack/
|
||||
mute-timings:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/mute-timings/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/mute-timings/
|
||||
alerting_export:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources/
|
||||
rbac-terraform-provisioning:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/roles-and-permissions/access-control/rbac-terraform-provisioning/
|
||||
notification-policy:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy/
|
||||
alerting-rules:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules/
|
||||
service-accounts:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/service-accounts/
|
||||
rbac-role-definitions:
|
||||
- pattern: /docs/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/administration/roles-and-permissions/access-control/rbac-fixed-basic-role-definitions/
|
||||
testdata:
|
||||
- pattern: /docs/grafana/
|
||||
destination: /docs/grafana/<GRAFANA_VERSION>/datasources/testdata/
|
||||
- pattern: /docs/grafana-cloud/
|
||||
destination: /docs/grafana-cloud/connect-externally-hosted/data-sources/testdata/
|
||||
---
|
||||
|
||||
# Use Terraform to provision alerting resources
|
||||
@ -27,7 +80,7 @@ To create and manage your alerting resources using Terraform, you have to comple
|
||||
|
||||
1. Create an API key to configure the Terraform provider.
|
||||
1. Create your alerting resources in Terraform format by
|
||||
- [exporting configured alerting resources][alerting_export]
|
||||
- [exporting configured alerting resources](ref:alerting_export)
|
||||
- or writing the [Terraform Alerting schemas](https://registry.terraform.io/providers/grafana/grafana/latest/docs).
|
||||
> By default, you cannot edit provisioned resources. Enable [`disable_provenance` in the Terraform resource](#enable-editing-resources-in-the-grafana-ui) to allow changes in the Grafana UI.
|
||||
1. Run `terraform apply` to provision your alerting resources.
|
||||
@ -36,10 +89,10 @@ Before you begin, you should have available a Grafana instance and [Terraform in
|
||||
|
||||
## Create an API key and configure the Terraform provider
|
||||
|
||||
You can create a [service account token][service-accounts] to authenticate Terraform with Grafana. To create an API key for provisioning alerting resources, complete the following steps.
|
||||
You can create a [service account token](ref:service-accounts) to authenticate Terraform with Grafana. To create an API key for provisioning alerting resources, complete the following steps.
|
||||
|
||||
1. Create a new service account.
|
||||
1. Assign the role or permission to access the [Alerting provisioning API][alerting_http_provisioning].
|
||||
1. Assign the role or permission to access the [Alerting provisioning API](ref:alerting_http_provisioning).
|
||||
1. Create a new service account token.
|
||||
1. Name and save the token for use in Terraform.
|
||||
|
||||
@ -68,29 +121,29 @@ Replace the following values:
|
||||
|
||||
This Terraform configuration installs the [Grafana Terraform provider](https://registry.terraform.io/providers/grafana/grafana/latest/docs) and authenticates against your Grafana instance using an API token. For other authentication alternatives including basic authentication, refer to the [`auth` option documentation](https://registry.terraform.io/providers/grafana/grafana/latest/docs#authentication).
|
||||
|
||||
For Grafana Cloud, refer to the [instructions to manage a Grafana Cloud stack with Terraform][provision-cloud-with-terraform]. For role-based access control, refer to [Provisioning RBAC with Terraform][rbac-terraform-provisioning] and the [alerting provisioning roles (`fixed:alerting.provisioning.*`)][rbac-role-definitions].
|
||||
For Grafana Cloud, refer to the [instructions to manage a Grafana Cloud stack with Terraform](ref:provision-cloud-with-terraform). For role-based access control, refer to [Provisioning RBAC with Terraform](ref:rbac-terraform-provisioning) and the [alerting provisioning roles (`fixed:alerting.provisioning.*`)](ref:rbac-role-definitions).
|
||||
|
||||
## Create Terraform configurations for alerting resources
|
||||
|
||||
[Grafana Terraform provider](https://registry.terraform.io/providers/grafana/grafana/latest/docs) enables you to manage the following alerting resources.
|
||||
|
||||
| Alerting resource | Terraform resource |
|
||||
| ----------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| [Alert rules][alerting-rules] | [grafana_rule_group](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/rule_group) |
|
||||
| [Contact points][contact-points] | [grafana_contact_point](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/contact_point) |
|
||||
| [Notification templates][notification-template] | [grafana_message_template](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/message_template) |
|
||||
| [Notification policy tree][notification-policy] | [grafana_notification_policy](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/notification_policy) |
|
||||
| [Mute timings][mute-timings] | [grafana_mute_timing](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/mute_timing) |
|
||||
| Alerting resource | Terraform resource |
|
||||
| --------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| [Alert rules](ref:alerting-rules) | [grafana_rule_group](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/rule_group) |
|
||||
| [Contact points](ref:contact-points) | [grafana_contact_point](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/contact_point) |
|
||||
| [Notification templates](ref:notification-template) | [grafana_message_template](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/message_template) |
|
||||
| [Notification policy tree](ref:notification-policy) | [grafana_notification_policy](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/notification_policy) |
|
||||
| [Mute timings](ref:mute-timings) | [grafana_mute_timing](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/mute_timing) |
|
||||
|
||||
This section provides examples of Terraform configurations for each alerting resource and demonstrate how to link them together.
|
||||
In this section, we'll create Terraform configurations for each alerting resource and demonstrate how to link them together.
|
||||
|
||||
### Add alert rules
|
||||
|
||||
[Alert rules][alerting-rules] enable you to receive alerts by querying any backend Grafana data sources.
|
||||
[Alert rules](ref:alerting-rules) enable you to receive alerts by querying any backend Grafana data sources.
|
||||
|
||||
1. First, create a data source to query and a folder to store your rules in.
|
||||
|
||||
In this example, the [TestData][testdata] data source is used.
|
||||
In this example, the [TestData](ref:testdata) data source is used.
|
||||
|
||||
```terraform
|
||||
resource "grafana_data_source" "<terraform_data_source_name>" {
|
||||
@ -110,7 +163,7 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
1. Create or find an alert rule you want to import in Grafana.
|
||||
|
||||
1. [Export][alerting_export] the alert rule group in Terraform format. This exports the alert rule group as [`grafana_rule_group` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/rule_group).
|
||||
1. [Export](ref:alerting_export) the alert rule group in Terraform format. This exports the alert rule group as [`grafana_rule_group` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/rule_group).
|
||||
|
||||
You can edit the exported resource, or alternatively, consider creating the resource from scratch.
|
||||
|
||||
@ -181,7 +234,7 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
- `<terraform_rule_group_name>` with the name of the alert rule group.
|
||||
|
||||
Note that the distinct Grafana resources are connected through `uid` values in their Terraform configurations. The `uid` value is randomly generated when provisioning.
|
||||
Note that the distinct Grafana resources are connected through `uid` values in their Terraform configurations. The `uid` value will be randomly generated when provisioning.
|
||||
|
||||
To link the alert rule group with its respective data source and folder in this example, replace the following field values:
|
||||
|
||||
@ -192,11 +245,11 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
### Add contact points
|
||||
|
||||
[Contact points][contact-points] are the receivers of alert notifications.
|
||||
[Contact points](ref:contact-points) are the receivers of alert notifications.
|
||||
|
||||
1. Create or find the contact points you want to import in Grafana. Alternatively, consider writing the resource in code as demonstrated in the example below.
|
||||
|
||||
1. [Export][alerting_export] the contact point in Terraform format. This exports the contact point as [`grafana_contact_point` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/contact_point)—edit it if necessary.
|
||||
1. [Export](ref:alerting_export) the contact point in Terraform format. This exports the contact point as [`grafana_contact_point` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/contact_point)—edit it if necessary.
|
||||
|
||||
1. In this example, notifications are muted on weekends.
|
||||
|
||||
@ -212,18 +265,18 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
Replace the following field values:
|
||||
|
||||
- `<terraform_contact_point_name>` with the terraform name of the contact point. It is used to reference the contact point in other Terraform resources.
|
||||
- `<terraform_contact_point_name>` with the terraform name of the contact point. It will be used to reference the contact point in other Terraform resources.
|
||||
- `<email_address>` with the email to receive alert notifications.
|
||||
|
||||
1. Continue to add more Grafana resources or [use the Terraform CLI for provisioning](#provision-grafana-resources-with-terraform).
|
||||
|
||||
### Add and enable templates
|
||||
|
||||
[Notification templates][notification-template] allow customization of alert notifications across multiple contact points.
|
||||
[Notification templates](ref:notification-template) allow customization of alert notifications across multiple contact points.
|
||||
|
||||
1. Create or find the notification template you want to import in Grafana. Alternatively, consider writing the resource in code as demonstrated in the example below.
|
||||
|
||||
1. [Export][alerting_export] the template as [`grafana_message_template` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/message_template).
|
||||
1. [Export](ref:alerting_export) the template as [`grafana_message_template` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/message_template).
|
||||
|
||||
This example is a simple demo template defined as `custom_email.message`.
|
||||
|
||||
@ -256,11 +309,11 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
### Add mute timings
|
||||
|
||||
[Mute timings][mute-timings] pause alert notifications during predetermined intervals.
|
||||
[Mute timings](ref:mute-timings) pause alert notifications during predetermined intervals.
|
||||
|
||||
1. Create or find the mute timings you want to import in Grafana. Alternatively, consider writing the resource in code as demonstrated in the example below.
|
||||
|
||||
1. [Export][alerting_export] the mute timing in Terraform format. This exports the mute timing as [`grafana_mute_timing` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/mute_timing)—edit it if necessary.
|
||||
1. [Export](ref:alerting_export) the mute timing in Terraform format. This exports the mute timing as [`grafana_mute_timing` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/mute_timing)—edit it if necessary.
|
||||
|
||||
1. This example turns off notifications on weekends.
|
||||
|
||||
@ -276,23 +329,23 @@ This section provides examples of Terraform configurations for each alerting res
|
||||
|
||||
Replace the following field values:
|
||||
|
||||
- `<terraform_mute_timing_name>` with the name of the Terraform resource. It is used to reference the mute timing in the Terraform notification policy tree.
|
||||
- `<terraform_mute_timing_name>` with the name of the Terraform resource. It will be used to reference the mute timing in the Terraform notification policy tree.
|
||||
|
||||
1. Continue to add more Grafana resources or [use the Terraform CLI for provisioning](#provision-grafana-resources-with-terraform).
|
||||
|
||||
### Add the notification policy tree
|
||||
|
||||
[Notification policies][notification-policy] defines how to route alert instances to your contact points.
|
||||
[Notification policies](ref:notification-policy) defines how to route alert instances to your contact points.
|
||||
|
||||
{{% admonition type="warning" %}}
|
||||
|
||||
Since the policy tree is a single resource, provisioning the `grafana_notification_policy` resource overwrites a policy tree created through any other means.
|
||||
Since the policy tree is a single resource, provisioning the `grafana_notification_policy` resource will overwrite a policy tree created through any other means.
|
||||
|
||||
{{< /admonition >}}
|
||||
|
||||
1. Find the default notification policy tree. Alternatively, consider writing the resource in code as demonstrated in the example below.
|
||||
|
||||
2. [Export][alerting_export] the notification policy tree in Terraform format. This exports it as [`grafana_notification_policy` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/notification_policy)—edit it if necessary.
|
||||
1. [Export](ref:alerting_export) the notification policy tree in Terraform format. This exports it as [`grafana_notification_policy` Terraform resource](https://registry.terraform.io/providers/grafana/grafana/latest/docs/resources/notification_policy)—edit it if necessary.
|
||||
|
||||
```terraform
|
||||
resource "grafana_notification_policy" "my_policy_tree" {
|
||||
@ -314,7 +367,7 @@ Since the policy tree is a single resource, provisioning the `grafana_notificati
|
||||
- `<terraform_data_source_name>` with the terraform name of the previously defined contact point.
|
||||
- `<terraform_folder_name>` with the terraform name of the previously defined mute timing.
|
||||
|
||||
3. Continue to add more Grafana resources or [use the Terraform CLI for provisioning](#provision-grafana-resources-with-terraform).
|
||||
1. Continue to add more Grafana resources or [use the Terraform CLI for provisioning](#provision-grafana-resources-with-terraform).
|
||||
|
||||
### Enable editing resources in the Grafana UI
|
||||
|
||||
@ -368,7 +421,7 @@ To create the previous alerting resources in Grafana with the Terraform CLI, com
|
||||
Enter a value:
|
||||
```
|
||||
|
||||
After you have confirmed to proceed with the changes, Terraform creates the provisioned resources in Grafana.
|
||||
Once you have confirmed to proceed with the changes, Terraform will create the provisioned resources in Grafana!
|
||||
|
||||
```shell
|
||||
Apply complete! Resources: 4 added, 0 changed, 0 destroyed.
|
||||
@ -382,40 +435,4 @@ For more examples on the concept of this guide:
|
||||
|
||||
- Try the demo [provisioning alerting resources in Grafana OSS using Terraform and Docker Compose](https://github.com/grafana/provisioning-alerting-examples/tree/main/terraform).
|
||||
- Review all the available options and examples of the Terraform Alerting schemas in the [Grafana Terraform Provider documentation](https://registry.terraform.io/providers/grafana/grafana/latest/docs).
|
||||
- Review the [tutorial to manage a Grafana Cloud stack using Terraform][provision-cloud-with-terraform].
|
||||
|
||||
{{% docs/reference %}}
|
||||
|
||||
[alerting-rules]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/alerting-rules"
|
||||
[alerting-rules]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/alerting-rules"
|
||||
|
||||
[contact-points]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points"
|
||||
[contact-points]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points"
|
||||
|
||||
[mute-timings]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/mute-timings"
|
||||
[mute-timings]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/mute-timings"
|
||||
|
||||
[notification-policy]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/create-notification-policy"
|
||||
[notification-policy]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/create-notification-policy"
|
||||
|
||||
[notification-template]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/template-notifications"
|
||||
[notification-template]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications"
|
||||
|
||||
[alerting_export]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/export-alerting-resources"
|
||||
[alerting_export]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/export-alerting-resources"
|
||||
|
||||
[alerting_http_provisioning]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
[alerting_http_provisioning]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/alerting-and-irm/alerting/set-up/provision-alerting-resources/http-api-provisioning"
|
||||
|
||||
[service-accounts]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/service-accounts"
|
||||
|
||||
[testdata]: "/docs/grafana/ -> /docs/grafana/<GRAFANA_VERSION>/datasources/testdata"
|
||||
[testdata]: "/docs/grafana-cloud/ -> /docs/grafana-cloud/connect-externally-hosted/data-sources/testdata"
|
||||
|
||||
[provision-cloud-with-terraform]: "/docs/ -> /docs/grafana-cloud/developer-resources/infrastructure-as-code/terraform/terraform-cloud-stack"
|
||||
|
||||
[rbac-role-definitions]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/roles-and-permissions/access-control/rbac-fixed-basic-role-definitions"
|
||||
|
||||
[rbac-terraform-provisioning]: "/docs/ -> /docs/grafana/<GRAFANA_VERSION>/administration/roles-and-permissions/access-control/rbac-terraform-provisioning"
|
||||
|
||||
{{% /docs/reference %}}
|
||||
- Review the [tutorial to manage a Grafana Cloud stack using Terraform](ref:provision-cloud-with-terraform).
|
||||
|
Loading…
Reference in New Issue
Block a user