Skip to content

Commit db481eb

Browse files
authored
Merge pull request grafana#87 from 58231/master
2 parents 990698f + 73356ba commit db481eb

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ module github.com/terraform-providers/terraform-provider-grafana
33
require (
44
github.com/hashicorp/hcl v1.0.0 // indirect
55
github.com/hashicorp/terraform v0.12.2
6-
github.com/nytm/go-grafana-api v0.3.1
6+
github.com/nytm/go-grafana-api v0.5.0
77
)

go.sum

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,8 @@ github.com/nytm/go-grafana-api v0.2.0 h1:Aa5h2zMKDGjY1gS0bfesAfwSeRdTZG1GF8it+Nk
300300
github.com/nytm/go-grafana-api v0.2.0/go.mod h1:YOJL2MOLAmCeqz0cbHU9tZIDj0OxpOiIFKSJXRbAorY=
301301
github.com/nytm/go-grafana-api v0.3.1 h1:UMQYx88ZIpAxW2GunD2JgNve4QJt/T31PQXIyEtxzEs=
302302
github.com/nytm/go-grafana-api v0.3.1/go.mod h1:YOJL2MOLAmCeqz0cbHU9tZIDj0OxpOiIFKSJXRbAorY=
303+
github.com/nytm/go-grafana-api v0.5.0 h1:8pIbNPNDguBa4aUNxcYl0GN247W6PXMvsOwiRBmk1sE=
304+
github.com/nytm/go-grafana-api v0.5.0/go.mod h1:YOJL2MOLAmCeqz0cbHU9tZIDj0OxpOiIFKSJXRbAorY=
303305
github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw=
304306
github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA=
305307
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=

grafana/resource_alert_notification.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ func ResourceAlertNotification() *schema.Resource {
5656
Optional: true,
5757
Sensitive: true,
5858
},
59+
60+
"uid": {
61+
Type: schema.TypeString,
62+
Optional: true,
63+
Computed: true,
64+
},
5965
},
6066
}
6167
}
@@ -125,6 +131,7 @@ func ReadAlertNotification(d *schema.ResourceData, meta interface{}) error {
125131
d.Set("name", alertNotification.Name)
126132
d.Set("type", alertNotification.Type)
127133
d.Set("settings", settings)
134+
d.Set("uid", alertNotification.Uid)
128135

129136
return nil
130137
}
@@ -179,6 +186,7 @@ func makeAlertNotification(d *schema.ResourceData) (*gapi.AlertNotification, err
179186
Name: d.Get("name").(string),
180187
Type: d.Get("type").(string),
181188
IsDefault: d.Get("is_default").(bool),
189+
Uid: d.Get("uid").(string),
182190
SendReminder: sendReminder,
183191
Frequency: frequency,
184192
Settings: settings,

0 commit comments

Comments
 (0)