Get the mountInfo by 'LookupMount' in containerd
Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
This commit is contained in:
@@ -43,7 +43,6 @@ type OS interface {
|
||||
WriteFile(filename string, data []byte, perm os.FileMode) error
|
||||
Mount(source string, target string, fstype string, flags uintptr, data string) error
|
||||
Unmount(target string, flags int) error
|
||||
GetMounts() ([]*mount.Info, error)
|
||||
LookupMount(path string) (containerdmount.Info, error)
|
||||
DeviceUUID(device uint64) (string, error)
|
||||
}
|
||||
@@ -121,11 +120,6 @@ func (RealOS) Unmount(target string, flags int) error {
|
||||
return unix.Unmount(target, flags)
|
||||
}
|
||||
|
||||
// GetMounts retrieves a list of mounts for the current running process.
|
||||
func (RealOS) GetMounts() ([]*mount.Info, error) {
|
||||
return mount.GetMounts()
|
||||
}
|
||||
|
||||
// LookupMount gets mount info of a given path.
|
||||
func (RealOS) LookupMount(path string) (containerdmount.Info, error) {
|
||||
return containerdmount.Lookup(path)
|
||||
|
||||
Reference in New Issue
Block a user