Skip to content

Commit

Permalink
fix: enable up to 64 chars for kubernetes autonaming
Browse files Browse the repository at this point in the history
  • Loading branch information
rquitales committed Feb 19, 2025
1 parent 0215fe1 commit df4f580
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions provider/resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -925,6 +925,15 @@ func Provider() tfbridge.ProviderInfo {
}
return pm, nil
},
Fields: map[string]*tfbridge.SchemaInfo{
// Use default autonaming options, but set max length to 64 as allowed by Azure.
azureName: tfbridge.AutoNameWithCustomOptions(azureName, tfbridge.AutoNameOptions{
Separator: "-",
Maxlen: 64,
Randlen: 7,
Transform: strings.ToLower,
}),
},
},
"azurerm_kubernetes_cluster_node_pool": {
Tok: azureResource(azureContainerService, "KubernetesClusterNodePool"),
Expand Down

0 comments on commit df4f580

Please sign in to comment.