@@ -22,6 +22,7 @@ import (
2222
2323const (
2424 type9pFs = "9p"
25+ typeVirtioFS = "virtio_fs"
2526 typeTmpFs = "tmpfs"
2627 devPrefix = "/dev/"
2728 timeoutHotplug = 3
@@ -98,7 +99,7 @@ func mount(source, destination, fsType string, flags int, options string) error
9899
99100 var err error
100101 switch fsType {
101- case type9pFs :
102+ case type9pFs , typeVirtioFS :
102103 if err = createDestinationDir (destination ); err != nil {
103104 return err
104105 }
@@ -191,6 +192,7 @@ type storageHandler func(storage pb.Storage, s *sandbox) (string, error)
191192// storageHandlerList lists the supported drivers.
192193var storageHandlerList = map [string ]storageHandler {
193194 driver9pType : virtio9pStorageHandler ,
195+ driverVirtioFSType : virtioFSStorageHandler ,
194196 driverBlkType : virtioBlkStorageHandler ,
195197 driverMmioBlkType : virtioMmioBlkStorageHandler ,
196198 driverSCSIType : virtioSCSIStorageHandler ,
@@ -217,6 +219,11 @@ func virtio9pStorageHandler(storage pb.Storage, s *sandbox) (string, error) {
217219 return commonStorageHandler (storage )
218220}
219221
222+ // virtioFSStorageHandler handles the storage for virtio-fs.
223+ func virtioFSStorageHandler (storage pb.Storage , s * sandbox ) (string , error ) {
224+ return commonStorageHandler (storage )
225+ }
226+
220227// virtioMmioBlkStorageHandler handles the storage for mmio blk driver.
221228func virtioMmioBlkStorageHandler (storage pb.Storage , s * sandbox ) (string , error ) {
222229 //The source path is VmPath
0 commit comments