Skip to content

Commit

Permalink
r/storage_container: exposing the resource_manager_id field
Browse files Browse the repository at this point in the history
  • Loading branch information
tombuildsstuff committed Mar 19, 2020
1 parent f09d998 commit e1840a4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,11 @@ func resourceArmStorageContainer() *schema.Resource {
Type: schema.TypeBool,
Computed: true,
},

"resource_manager_id": {
Type: schema.TypeString,
Computed: true,
},
},
}
}
Expand Down Expand Up @@ -227,6 +232,9 @@ func resourceArmStorageContainerRead(d *schema.ResourceData, meta interface{}) e
d.Set("has_immutability_policy", props.HasImmutabilityPolicy)
d.Set("has_legal_hold", props.HasLegalHold)

resourceManagerId := client.GetResourceManagerResourceID(storageClient.SubscriptionId, account.ResourceGroup, id.AccountName, id.ContainerName)
d.Set("resource_manager_id", resourceManagerId)

return nil
}

Expand Down
2 changes: 2 additions & 0 deletions website/docs/r/storage_container.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ The following attributes are exported in addition to the arguments listed above:

* `has_legal_hold` - Is there a Legal Hold configured on this Storage Container?

* `resource_manager_id` - The Resource Manager ID of this Storage Container.

## Timeouts

The `timeouts` block allows you to specify [timeouts](https://www.terraform.io/docs/configuration/resources.html#timeouts) for certain actions:
Expand Down

0 comments on commit e1840a4

Please sign in to comment.