Move fs.Context to types.go
This config struct is now used in the plugin InitializeContext method, so it should be defined in the os-neutral types.go file
This commit is contained in:
parent
a022fa71b7
commit
f8a73e018b
17
fs/fs.go
17
fs/fs.go
@ -91,23 +91,6 @@ type RealFsInfo struct {
|
|||||||
fsUUIDToDeviceName map[string]string
|
fsUUIDToDeviceName map[string]string
|
||||||
}
|
}
|
||||||
|
|
||||||
type Context struct {
|
|
||||||
// docker root directory.
|
|
||||||
Docker DockerContext
|
|
||||||
RktPath string
|
|
||||||
Crio CrioContext
|
|
||||||
}
|
|
||||||
|
|
||||||
type DockerContext struct {
|
|
||||||
Root string
|
|
||||||
Driver string
|
|
||||||
DriverStatus map[string]string
|
|
||||||
}
|
|
||||||
|
|
||||||
type CrioContext struct {
|
|
||||||
Root string
|
|
||||||
}
|
|
||||||
|
|
||||||
func NewFsInfo(context Context) (FsInfo, error) {
|
func NewFsInfo(context Context) (FsInfo, error) {
|
||||||
mounts, err := mount.GetMounts(nil)
|
mounts, err := mount.GetMounts(nil)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
17
fs/types.go
17
fs/types.go
@ -18,6 +18,23 @@ import (
|
|||||||
"errors"
|
"errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
type Context struct {
|
||||||
|
// docker root directory.
|
||||||
|
Docker DockerContext
|
||||||
|
RktPath string
|
||||||
|
Crio CrioContext
|
||||||
|
}
|
||||||
|
|
||||||
|
type DockerContext struct {
|
||||||
|
Root string
|
||||||
|
Driver string
|
||||||
|
DriverStatus map[string]string
|
||||||
|
}
|
||||||
|
|
||||||
|
type CrioContext struct {
|
||||||
|
Root string
|
||||||
|
}
|
||||||
|
|
||||||
type DeviceInfo struct {
|
type DeviceInfo struct {
|
||||||
Device string
|
Device string
|
||||||
Major uint
|
Major uint
|
||||||
|
Loading…
Reference in New Issue
Block a user