MCPcopy Create free account
hub / github.com/NVIDIA/gpu-operator / isDevRoot

Method isDevRoot

cmd/nvidia-validator/find.go:66–72  ·  view source on GitHub ↗

isDevRoot checks whether the specified root is a dev root. A dev root is defined as a root containing a /dev folder.

()

Source from the content-addressed store, hash-verified

64// isDevRoot checks whether the specified root is a dev root.
65// A dev root is defined as a root containing a /dev folder.
66func (r root) isDevRoot() bool {
67 stat, err := os.Stat(filepath.Join(string(r), "dev"))
68 if err != nil {
69 return false
70 }
71 return stat.IsDir()
72}
73
74// getDevRoot returns the dev root associated with the root.
75// If the root is not a dev root, this defaults to "/".

Callers 1

getDevRootMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected