Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

azurerm_netapp_account SMB server name check is too restrictive #11674

Closed
lucaghersi opened this issue May 12, 2021 · 1 comment · Fixed by #25340
Closed

azurerm_netapp_account SMB server name check is too restrictive #11674

lucaghersi opened this issue May 12, 2021 · 1 comment · Fixed by #25340

Comments

@lucaghersi
Copy link

lucaghersi commented May 12, 2021

Terraform (and AzureRM Provider) Version:

  • Terraform v0.15.1
  • Provider hashicorp/azurerm v2.57.0

Affected resource:

  • azurerm_netapp_account

Configuration file example:

resource "azurerm_netapp_account" "dev-netapp-fs-gwc-001" {
  name                = "dev-netapp-fs-gwc-001"
  resource_group_name = azurerm_resource_group.dev-rg-netapp-fs.name
  location            = local.germany_west_central

  active_directory {
    username            = "netappfs"
    password            = data.azurerm_key_vault_secret.netappfs-user-password.value
    smb_server_name     = "FP-AFS-"
    dns_servers         = ["10.101.32.36", "10.101.32.37"]
    domain              = "XXX.XX"
    organizational_unit = "OU=Azure,OU=FileServer,OU=Server"
  }
}

Expected Behaviour:

I would expect this resource to be created.

Actual Behaviour:

Error: invalid value for active_directory.0.smb_server_name (The smb server name can not be longer than 10 characters in length.)

The smb_server_name regex is too restrictive and does not allow a computer name that includes any character other than digits or letters (capital and not capital) while instead is perfectly fine to use other characters in the portal.
The error message is also confusing as, in fact, the string length is below 10 in length.

Screenshot 2021-05-12 at 11 08 25

https://github.com/terraform-providers/terraform-provider-azurerm/blob/9d5d4dcc7ef9a350981565614b6b3d72874bbf2a/azurerm/internal/services/netapp/netapp_account_resource.go#L75

Copy link

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants