hashicorp / terraform-provider-azurerm

Terraform provider for Azure Resource Manager
https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs
Mozilla Public License 2.0
4.62k stars 4.66k forks source link

azurerm_vmware_private_cloud does not export vcenter and nsx password when used as data #21993

Open khensler-msft opened 1 year ago

khensler-msft commented 1 year ago

Is there an existing issue for this?

Community Note

Terraform Version

latest

AzureRM Provider Version

latest

Affected Resource(s)/Data Source(s)

azurerm_vmware_private_cloud

Terraform Configuration Files

terraform {
  required_providers {
    vsphere = {
      source = "hashicorp/vsphere"    
    }
    azurerm = {
      source = "hashicorp/azurerm"
      version = ">2.69.0"
    }
}
}

provider "azurerm" {
  features {
    resource_group {
      prevent_deletion_if_contains_resources = false  
    }
  }
  subscription_id = "xxx-xx-xx"
}

data "azurerm_vmware_private_cloud" "avs-pc-01" {
  name                = "name"
  location            = "region"
  resource_group_name = "resource group name"
}

provider "vsphere" {
  user  = "cloudadmin@vsphere.local"
  password = data.azurerm_vmware_private_cloud.avs-pc-01.vcenter_password
  vsphere_server       = data.azurerm_vmware_private_cloud.avs-pc-01.vcsa_endpoint
  allow_unverified_ssl = true
  client_debug = false
  alias = "vc01"
}

data "vsphere_datacenter" "dc1" {
  provider = vsphere.vc01
}

Debug Output/Panic Output

│ Error: Unsupported attribute
│ 
│   on main.tf line 34, in provider "vsphere":
│   34:   password             = data.azurerm_vmware_private_cloud.avs-pc-01.vcenter_password

Expected Behaviour

the password should have been available

Actual Behaviour

the provider does not export this

Steps to Reproduce

terraform apply

Important Factoids

no

References

no

jiaweitao001 commented 1 year ago

Hi @khensler-msft , thanks for opening the issue. Currently, azurerm_vmware_private_cloud does not have this vcenter_password as an output. We would like to provide it but there's some quota issue on our test node, so unfortunately, we do not have an ETA for this. We will keep you posted here. Thanks.

khensler-msft commented 1 year ago

if you need access to a cloud or need help with quota feel free to reach out to me internally