Your version of Terraform is out of date! The latest version
is 0.13.1. You can update by downloading from https://www.terraform.io/downloads.html
Terraform v0.13.0
+ provider registry.terraform.io/hashicorp/azuread v0.11.0
+ provider registry.terraform.io/hashicorp/azurerm v2.24.0
azurerm_key_vaultresource "azurerm_key_vault" "kv" {
name = "snapshot-${var.prefix}-keyvault"
location = azurerm_resource_group.rg.location
resource_group_name = azurerm_resource_group.rg.name
enabled_for_disk_encryption = true
tenant_id = data.azurerm_client_config.current.tenant_id
soft_delete_enabled = true
soft_delete_retention_days = 7
purge_protection_enabled = false
sku_name = "standard"
}
Error: Unsupported argument
on main.tf line 54, in resource "azurerm_key_vault" "kv":
54: soft_delete_retention_days = 7
An argument named "soft_delete_retention_days" is not expected here.
This is pretty much a copy of the example from the docs. This should set the soft delete retention days to 7.
Error message generated. It's not clear how I set this property anymore?
terraform plan
hi @sonic1981
Thanks for opening this issue.
Taking a look into this this is available from v2.25.0 of the Azure Provider - you're currently using v2.24.0 - which you can upgrade to by updating the version in the Provider block (as shown below) and then running terraform init -upgrade:
provider "azurerm" {
version = "=2.25.0"
}
.. which should solve this for you - would you be able to take a look and see if that works for you? Since this should be fixed by upgrading the version of the provider being used here I'm going to close this issue for the moment - but please let us know if that doesn't work for you and we'll take another look.
Thanks!
ah good one, Thanks @tombuildsstuff Out of interested how did you find that out?
@sonic1981 I reviewed/merged it, but it's also in the changelog :)
I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues.
If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!