Skip to content

Commit cd2c8cb

Browse files
committed
Fix pv reclaim failed due to its phase is wrongly updated to the Failed state by kcm
1 parent 41f2182 commit cd2c8cb

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

pkg/controller/volume/persistentvolume/pv_controller.go

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1935,16 +1935,14 @@ func (ctrl *PersistentVolumeController) findDeletablePlugin(volume *v1.Persisten
19351935
}
19361936
}
19371937

1938-
if utilfeature.DefaultFeatureGate.Enabled(features.HonorPVReclaimPolicy) {
1939-
if metav1.HasAnnotation(volume.ObjectMeta, storagehelpers.AnnMigratedTo) {
1940-
// CSI migration scenario - do not depend on in-tree plugin
1941-
return nil, nil
1942-
}
1938+
if metav1.HasAnnotation(volume.ObjectMeta, storagehelpers.AnnMigratedTo) {
1939+
// CSI migration scenario - do not depend on in-tree plugin
1940+
return nil, nil
1941+
}
19431942

1944-
if volume.Spec.CSI != nil {
1945-
// CSI volume source scenario - external provisioner is requested
1946-
return nil, nil
1947-
}
1943+
if volume.Spec.CSI != nil {
1944+
// CSI volume source scenario - external provisioner is requested
1945+
return nil, nil
19481946
}
19491947

19501948
// The plugin that provisioned the volume was not found or the volume

0 commit comments

Comments
 (0)