Merge pull request #95569 from oomichi/remove-kubelet-util
Move dirExists() to kubelet_test
This commit is contained in:
@@ -2075,6 +2075,15 @@ func runVolumeManager(kubelet *Kubelet) chan struct{} {
|
||||
return stopCh
|
||||
}
|
||||
|
||||
// dirExists returns true if the path exists and represents a directory.
|
||||
func dirExists(path string) bool {
|
||||
s, err := os.Stat(path)
|
||||
if err != nil {
|
||||
return false
|
||||
}
|
||||
return s.IsDir()
|
||||
}
|
||||
|
||||
// Sort pods by UID.
|
||||
type podsByUID []*v1.Pod
|
||||
|
||||
|
Reference in New Issue
Block a user