Just kind of started wondering what the background on the design as to why when I define an azrurerm provider block, that it handles the registration of Microsoft’s (feature) providers ?
I saw the new options regarding the registration of Microsoft providers in v4 and it made me want to ask why are providers handled in the Terraform provider and not azurerm_subscription
?
Why
provider "azurerm" {
resource_provider_registrations = "core"
resource_providers_to_register = [
"Microsoft.ContainerService",
"Microsoft.KeyVault",
]
}
and not
resource "azurerm_subscription" "example" {
subscription_name = "My Example EA Subscription"
billing_scope_id = data.azurerm_billing_enrollment_account_scope.example.id
resource_providers_to_register = [
"Microsoft.ContainerService",
"Microsoft.KeyVault",
]
}