How would you be able to reference an attribute from the vsphere_datacenter data source for use with the datacenter_id argument within the vsphere_folder resource in the following configuration?
How would you be able to reference an attribute from the vsphere_datacenter data source for use with the datacenter_id argument within the vsphere_folder resource in the following configuration?
To reference an attribute from the vsphere_datacenter data source for use with the datacenter_id argument within the vsphere_folder resource, the correct syntax follows the format data.<TYPE>.<NAME>.<ATTRIBUTE>. In this case, the type is vsphere_datacenter, the name is dc, and the attribute we want to reference is id. Therefore, the correct reference is data.vsphere_datacenter.dc.id.
data.<TYPE>.<NAME>.<ATTRIBUTE>
D: data "azurerm_resource_group" "example" { name = "existing" } output "id" { value = data.azurerm_resource_group.example.id }
D is correct
I will go for D
yea correct, D, provider.resourcetype.name.id