Skip to content

Commit f745bac

Browse files
committed
Do not default to a filesytem type
1 parent f3eb9f7 commit f745bac

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

pkg/resizer/csi_resizer.go

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,6 @@ import (
3737
"k8s.io/klog"
3838
)
3939

40-
const (
41-
defaultFSType = "ext4"
42-
)
43-
4440
var (
4541
controllerServiceNotSupportErr = errors.New("CSI driver does not support controller service")
4642
resizeNotSupportErr = errors.New("CSI driver neither supports controller resize nor node resize")
@@ -235,9 +231,6 @@ func GetVolumeCapabilities(pvSpec v1.PersistentVolumeSpec) (*csilib.VolumeCapabi
235231

236232
} else {
237233
fsType := pvSpec.CSI.FSType
238-
if len(fsType) == 0 {
239-
fsType = defaultFSType
240-
}
241234

242235
cap = &csilib.VolumeCapability{
243236
AccessType: &csilib.VolumeCapability_Mount{

pkg/resizer/csi_resizer_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,7 @@ func TestResizeMigratedPV(t *testing.T) {
192192
func TestGetVolumeCapabilities(t *testing.T) {
193193
blockVolumeMode := v1.PersistentVolumeMode(v1.PersistentVolumeBlock)
194194
filesystemVolumeMode := v1.PersistentVolumeMode(v1.PersistentVolumeFilesystem)
195+
defaultFSType := ""
195196

196197
tests := []struct {
197198
name string

0 commit comments

Comments
 (0)