aztfmod / terraform-provider-azurecaf

Terraform provider for the Terraform platform engineering for Azure
MIT License
174 stars 93 forks source link

Invalid name for CAF naming azurerm_key_vault vmsecrets, the pattern ^[a-zA-Z][a-zA-Z0-9-]{1,22}[a-zA-Z0-9]$ doesn't match 5-kv-vmsecrets #73

Closed LaurentLesle closed 2 years ago

LaurentLesle commented 3 years ago

Error when setting the prefix value to "5"

nyuen commented 3 years ago

Can you attach the code to reproduce?

nyuen commented 3 years ago

@LaurentLesle Keyvault cannot start with a numeric value and doesn't accept 5 as a prefix

Vault name must only contain alphanumeric characters and dashes and cannot start with a number. Vault name must be between 3-24 alphanumeric characters. The name must begin with a letter, end with a letter or digit, and not contain consecutive hyphens

nyuen commented 3 years ago

Re-opening for discussion.

The prefix is not valid and the error message is expected. Two option :

  1. leave the error message as this is expected
  2. prevent prefix starting with a number

Open to discussion @LaurentLesle, @Nepomuceno,

arnaudlh commented 2 years ago

Closing as expired.