Merge pull request #10500 from squarti/fix-10499

runtime: Files are not synced between host and guest VMs
This commit is contained in:
Fabiano Fidêncio 2024-11-07 08:28:53 +01:00 committed by GitHub
commit c332e953f9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -64,6 +64,14 @@ func resolveRootDir() string {
// Use the default root dir in case of any errors resolving the root dir symlink
return defaultKubernetesRootDir
}
// Make root dir an absolute path if needed
if !filepath.IsAbs(rootDir) {
rootDir, err = filepath.Abs(filepath.Join(filepath.Dir(defaultKubernetesRootDir), rootDir))
if err != nil {
// Use the default root dir in case of any errors resolving the root dir symlink
return defaultKubernetesRootDir
}
}
return rootDir
}