mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-14 13:45:06 +00:00
Call MountDevice only once
Cann MountDevice only when the volume was not device-mounted before.
This commit is contained in:
@@ -568,7 +568,7 @@ func (og *operationGenerator) GenerateMountVolumeFunc(
|
|||||||
DevicePath: devicePath,
|
DevicePath: devicePath,
|
||||||
}
|
}
|
||||||
|
|
||||||
if volumeDeviceMounter != nil {
|
if volumeDeviceMounter != nil && actualStateOfWorld.GetDeviceMountState(volumeToMount.VolumeName) != DeviceGloballyMounted {
|
||||||
deviceMountPath, err :=
|
deviceMountPath, err :=
|
||||||
volumeDeviceMounter.GetDeviceMountPath(volumeToMount.VolumeSpec)
|
volumeDeviceMounter.GetDeviceMountPath(volumeToMount.VolumeSpec)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
Reference in New Issue
Block a user