mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 05:03:09 +00:00
Merge pull request #100731 from kassarl/azurefile-InvalidCharacter-issue
Normalize share name to not include capital letters
This commit is contained in:
commit
a55bd63172
@ -198,9 +198,10 @@ func (a *azureFileProvisioner) Provision(selectedNode *v1.Node, allowedTopologie
|
|||||||
}
|
}
|
||||||
|
|
||||||
if shareName == "" {
|
if shareName == "" {
|
||||||
// File share name has a length limit of 63, and it cannot contain two consecutive '-'s.
|
// File share name has a length limit of 63, it cannot contain two consecutive '-'s, and all letters must be lower case.
|
||||||
name := util.GenerateVolumeName(a.options.ClusterName, a.options.PVName, 63)
|
name := util.GenerateVolumeName(a.options.ClusterName, a.options.PVName, 63)
|
||||||
shareName = strings.Replace(name, "--", "-", -1)
|
shareName = strings.Replace(name, "--", "-", -1)
|
||||||
|
shareName = strings.ToLower(shareName)
|
||||||
}
|
}
|
||||||
|
|
||||||
if resourceGroup == "" {
|
if resourceGroup == "" {
|
||||||
|
Loading…
Reference in New Issue
Block a user