Alerting: Use stable identifier of a group when export to HCL (#90196)

* change the rule-group to be hashed when exporting to HCL

Signed-off-by: Aviv Guiser <avivguiser@gmail.com>

---------

Signed-off-by: Aviv Guiser <avivguiser@gmail.com>
This commit is contained in:
AvivGuiser
2024-07-19 18:13:26 +03:00
committed by GitHub
parent a61cd94a70
commit 96c3e9c550
3 changed files with 9 additions and 4 deletions

View File

@@ -760,7 +760,7 @@ func TestProvisioningApi(t *testing.T) {
insertRule(t, sut, rule1)
insertRule(t, sut, createTestAlertRule("rule2", 1))
expectedResponse := `resource "grafana_rule_group" "rule_group_0000" {
expectedResponse := `resource "grafana_rule_group" "rule_group_cc0954af8a53fa18" {
org_id = 1
name = "my-cool-group"
folder_uid = "folder-uid"