mirror of
https://github.com/kubernetes/kubernetes.git
synced 2026-06-09 00:34:10 -04:00
Pass additional flags to subpath mount to avoid flakes in certain conditions
This commit is contained in:
parent
ce5e9f6c83
commit
2a03546bf0
1 changed files with 2 additions and 1 deletions
|
|
@ -209,8 +209,9 @@ func doBindSubPath(mounter MountInterface, subpath Subpath) (hostPath string, er
|
|||
|
||||
// Do the bind mount
|
||||
options := []string{"bind"}
|
||||
mountFlags := []string{"--no-canonicalize"}
|
||||
klog.V(5).Infof("bind mounting %q at %q", mountSource, bindPathTarget)
|
||||
if err = mounter.Mount(mountSource, bindPathTarget, "" /*fstype*/, options); err != nil {
|
||||
if err = mounter.MountSensitiveWithFlags(mountSource, bindPathTarget, "" /*fstype*/, options, nil /* sensitiveOptions */, mountFlags); err != nil {
|
||||
return "", fmt.Errorf("error mounting %s: %s", subpath.Path, err)
|
||||
}
|
||||
success = true
|
||||
|
|
|
|||
Loading…
Reference in a new issue