Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Resource: azurerm_monitor_activitylog_alert #1989

Merged
merged 11 commits into from
Oct 15, 2018
9 changes: 7 additions & 2 deletions azurerm/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,9 @@ type ArmClient struct {
managementGroupsSubscriptionClient managementgroups.SubscriptionsClient

// Monitor
monitorActionGroupsClient insights.ActionGroupsClient
monitorAlertRulesClient insights.AlertRulesClient
monitorActionGroupsClient insights.ActionGroupsClient
monitorActivityLogAlertsClient insights.ActivityLogAlertsClient
monitorAlertRulesClient insights.AlertRulesClient

// MSI
userAssignedIdentitiesClient msi.UserAssignedIdentitiesClient
Expand Down Expand Up @@ -846,6 +847,10 @@ func (c *ArmClient) registerMonitorClients(endpoint, subscriptionId string, auth
c.configureClient(&agc.Client, auth)
c.monitorActionGroupsClient = agc

alac := insights.NewActivityLogAlertsClientWithBaseURI(endpoint, subscriptionId)
c.configureClient(&alac.Client, auth)
c.monitorActivityLogAlertsClient = alac

arc := insights.NewAlertRulesClientWithBaseURI(endpoint, subscriptionId)
c.configureClient(&arc.Client, auth)
c.monitorAlertRulesClient = arc
Expand Down
1 change: 1 addition & 0 deletions azurerm/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ func Provider() terraform.ResourceProvider {
"azurerm_management_group": resourceArmManagementGroup(),
"azurerm_metric_alertrule": resourceArmMetricAlertRule(),
"azurerm_monitor_action_group": resourceArmMonitorActionGroup(),
"azurerm_monitor_activity_log_alert": resourceArmMonitorActivityLogAlert(),
"azurerm_mysql_configuration": resourceArmMySQLConfiguration(),
"azurerm_mysql_database": resourceArmMySqlDatabase(),
"azurerm_mysql_firewall_rule": resourceArmMySqlFirewallRule(),
Expand Down
Loading