Merge pull request #101441 from dobsonj/101332-deprecate-mount-path-removal

Deprecate removal of CSI nodepublish path by kubelet (#101332)
This commit is contained in:
Kubernetes Prow Robot 2021-04-28 10:32:50 -07:00 committed by GitHub
commit 7f8539ff20
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -365,7 +365,11 @@ func (c *csiMountMgr) TearDownAt(dir string) error {
return errors.New(log("mounter.TearDownAt failed: %v", err))
}
// clean mount point dir
// Deprecation: Removal of target_path provided in the NodePublish RPC call
// (in this case location `dir`) MUST be done by the CSI plugin according
// to the spec. This will no longer be done directly as part of TearDown
// by the kubelet in the future. Kubelet will only be responsible for
// removal of json data files it creates and parent directories.
if err := removeMountDir(c.plugin, dir); err != nil {
return errors.New(log("mounter.TearDownAt failed to clean mount dir [%s]: %v", dir, err))
}