@@ -258,15 +258,15 @@ type AlertRuleGroupExport struct {
258
258
259
259
// AlertRuleExport is the provisioned file export of models.AlertRule.
260
260
type AlertRuleExport struct {
261
- UID string `json:"uid,omitempty" yaml:"uid,omitempty"`
262
- Title string `json:"title" yaml:"title" hcl:"name"`
263
- Condition string `json:"condition" yaml:"condition" hcl:"condition"`
264
- Data []AlertQueryExport `json:"data" yaml:"data" hcl:"data,block"`
265
- DashboardUID * string `json:"dashboardUid,omitempty" yaml:"dashboardUid,omitempty"`
266
- PanelID * int64 `json:"panelId,omitempty" yaml:"panelId,omitempty"`
267
- NoDataState NoDataState `json:"noDataState" yaml:"noDataState" hcl:"no_data_state"`
268
- ExecErrState ExecutionErrorState `json:"execErrState" yaml:"execErrState" hcl:"exec_err_state"`
269
- For model.Duration `json:"for" yaml:"for"`
261
+ UID string `json:"uid,omitempty" yaml:"uid,omitempty"`
262
+ Title string `json:"title" yaml:"title" hcl:"name"`
263
+ Condition * string `json:"condition,omitempty " yaml:"condition,omitempty " hcl:"condition"`
264
+ Data []AlertQueryExport `json:"data" yaml:"data" hcl:"data,block"`
265
+ DashboardUID * string `json:"dashboardUid,omitempty" yaml:"dashboardUid,omitempty"`
266
+ PanelID * int64 `json:"panelId,omitempty" yaml:"panelId,omitempty"`
267
+ NoDataState * NoDataState `json:"noDataState,omitempty " yaml:"noDataState,omitempty " hcl:"no_data_state"`
268
+ ExecErrState * ExecutionErrorState `json:"execErrState,omitempty " yaml:"execErrState,omitempty " hcl:"exec_err_state"`
269
+ For model.Duration `json:"for,omitempty " yaml:"for,omitempty "`
270
270
// ForString is used to:
271
271
// - Only export the for field for HCL if it is non-zero.
272
272
// - Format the Prometheus model.Duration type properly for HCL.
@@ -275,7 +275,7 @@ type AlertRuleExport struct {
275
275
Labels * map [string ]string `json:"labels,omitempty" yaml:"labels,omitempty" hcl:"labels"`
276
276
IsPaused bool `json:"isPaused" yaml:"isPaused" hcl:"is_paused"`
277
277
NotificationSettings * AlertRuleNotificationSettingsExport `json:"notification_settings,omitempty" yaml:"notification_settings,omitempty" hcl:"notification_settings,block"`
278
- Record * AlertRuleRecordExport `json:"record,omitempty" yaml:"record,omitempty" hcl:"record"`
278
+ Record * AlertRuleRecordExport `json:"record,omitempty" yaml:"record,omitempty" hcl:"record,block "`
279
279
}
280
280
281
281
// AlertQueryExport is the provisioned export of models.AlertQuery.
0 commit comments