Merge pull request #90608 from huffmanca/update-default-fstype-cinder

Updates the fstype of Cinder volumes to be ext4 if nil
This commit is contained in:
Kubernetes Prow Robot 2020-05-15 08:57:37 -07:00 committed by GitHub
commit ab207be846
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -570,6 +570,10 @@ func (c *cinderVolumeProvisioner) Provision(selectedNode *v1.Node, allowedTopolo
return nil, err return nil, err
} }
if fstype == "" {
fstype = "ext4"
}
volumeMode := c.options.PVC.Spec.VolumeMode volumeMode := c.options.PVC.Spec.VolumeMode
if volumeMode != nil && *volumeMode == v1.PersistentVolumeBlock { if volumeMode != nil && *volumeMode == v1.PersistentVolumeBlock {
// Block volumes should not have any FSType // Block volumes should not have any FSType