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.61k stars 4.65k forks source link

azurerm_automation_software_update_configuration - fix linux update classification to use a comma separated string #18595

Open daisy-timms-xlab opened 2 years ago

daisy-timms-xlab commented 2 years ago

Is there an existing issue for this?

Community Note

Terraform Version

0.14.5

AzureRM Provider Version

3.25.0

Affected Resource(s)/Data Source(s)

azurerm_automation_software_update_configuration

Terraform Configuration Files

resource "azurerm_automation_software_update_configuration" "example" {
  name                  = "example"
  automation_account_id = azurerm_automation_account.test.id
  operating_system      = "Linux"

  windows {
    classification_included = "Critical, Security"
    reboot                  = "IfRequired"
  }

  duration = "PT2H2M2S"
}

Debug Output/Panic Output

| Error: expected linux.0.classification_included to be one of [Critical Other Security Unclassified], got Critical,Security

Expected Behaviour

The plan should succeed with any combination of the possible classification values

Actual Behaviour

The resource validation will only accept a single classification.

Steps to Reproduce

terraform plan

Important Factoids

No response

References

https://github.com/hashicorp/terraform-provider-azurerm/issues/18537

dbhaigh commented 1 year ago

This problem used to exist for windows as well but the inclusion of "classifications_included" into the "windows" block has resolved this problem

When can the linux block see the same love?