Skip to content

Commit

Permalink
msi: updating to use API version 2018-11-30 rather than the Preview (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
tombuildsstuff authored Jan 14, 2021
1 parent c10a3e7 commit 90fc397
Show file tree
Hide file tree
Showing 12 changed files with 148 additions and 41 deletions.
2 changes: 1 addition & 1 deletion azurerm/internal/services/msi/client/client.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"github.com/Azure/azure-sdk-for-go/services/preview/msi/mgmt/2015-08-31-preview/msi"
"github.com/Azure/azure-sdk-for-go/services/msi/mgmt/2018-11-30/msi"
"github.com/terraform-providers/terraform-provider-azurerm/azurerm/internal/common"
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func dataSourceArmUserAssignedIdentityRead(d *schema.ResourceData, meta interfac

d.Set("location", location.NormalizeNilable(resp.Location))

if props := resp.IdentityProperties; props != nil {
if props := resp.UserAssignedIdentityProperties; props != nil {
if principalId := props.PrincipalID; principalId != nil {
d.Set("principal_id", principalId.String())
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/msi/mgmt/2015-08-31-preview/msi"
"github.com/Azure/azure-sdk-for-go/services/msi/mgmt/2018-11-30/msi"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/validation"
"github.com/terraform-providers/terraform-provider-azurerm/azurerm/helpers/azure"
Expand Down Expand Up @@ -126,7 +126,7 @@ func resourceArmUserAssignedIdentityRead(d *schema.ResourceData, meta interface{
d.Set("resource_group_name", id.ResourceGroup)
d.Set("location", location.NormalizeNilable(resp.Location))

if props := resp.IdentityProperties; props != nil {
if props := resp.UserAssignedIdentityProperties; props != nil {
if principalId := props.PrincipalID; principalId != nil {
d.Set("principal_id", principalId.String())
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (r UserAssignedIdentityResource) Exists(ctx context.Context, client *client
return nil, fmt.Errorf("retrieving User Assigned Identity %q (Resource Group %q): %+v", id.Name, id.ResourceGroup, err)
}

return utils.Bool(resp.IdentityProperties != nil), nil
return utils.Bool(resp.UserAssignedIdentityProperties != nil), nil
}

func (r UserAssignedIdentityResource) basic(data acceptance.TestData) string {
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ github.com/Azure/azure-sdk-for-go/services/maps/mgmt/2018-05-01/maps
github.com/Azure/azure-sdk-for-go/services/mariadb/mgmt/2018-06-01/mariadb
github.com/Azure/azure-sdk-for-go/services/marketplaceordering/mgmt/2015-06-01/marketplaceordering
github.com/Azure/azure-sdk-for-go/services/mediaservices/mgmt/2020-05-01/media
github.com/Azure/azure-sdk-for-go/services/msi/mgmt/2018-11-30/msi
github.com/Azure/azure-sdk-for-go/services/mysql/mgmt/2020-01-01/mysql
github.com/Azure/azure-sdk-for-go/services/netapp/mgmt/2019-10-01/netapp
github.com/Azure/azure-sdk-for-go/services/network/mgmt/2020-03-01/network
Expand All @@ -74,7 +75,6 @@ github.com/Azure/azure-sdk-for-go/services/preview/hardwaresecuritymodules/mgmt/
github.com/Azure/azure-sdk-for-go/services/preview/maintenance/mgmt/2018-06-01-preview/maintenance
github.com/Azure/azure-sdk-for-go/services/preview/mixedreality/mgmt/2019-02-28/mixedreality
github.com/Azure/azure-sdk-for-go/services/preview/monitor/mgmt/2019-06-01/insights
github.com/Azure/azure-sdk-for-go/services/preview/msi/mgmt/2015-08-31-preview/msi
github.com/Azure/azure-sdk-for-go/services/preview/operationsmanagement/mgmt/2015-11-01-preview/operationsmanagement
github.com/Azure/azure-sdk-for-go/services/preview/policyinsights/mgmt/2019-10-01-preview/policyinsights
github.com/Azure/azure-sdk-for-go/services/preview/portal/mgmt/2019-01-01-preview/portal
Expand Down

0 comments on commit 90fc397

Please sign in to comment.