mirror of
https://github.com/docker/cli.git
synced 2026-01-13 18:22:35 +03:00
Merge pull request #33422 from cpuguy83/dont_unmount_all_the_things
Don't unmount entire plugin manager tree on remove Upstream-commit: c12becaca72e705b7a52c8a8aeb498db880d0203 Component: engine
This commit is contained in:
@@ -633,8 +633,8 @@ func (pm *Manager) Remove(name string, config *types.PluginRmConfig) error {
|
||||
id := p.GetID()
|
||||
pm.config.Store.Remove(p)
|
||||
pluginDir := filepath.Join(pm.config.Root, id)
|
||||
if err := recursiveUnmount(pm.config.Root); err != nil {
|
||||
logrus.WithField("dir", pm.config.Root).WithField("id", id).Warn(err)
|
||||
if err := recursiveUnmount(pluginDir); err != nil {
|
||||
logrus.WithField("dir", pluginDir).WithField("id", id).Warn(err)
|
||||
}
|
||||
if err := os.RemoveAll(pluginDir); err != nil {
|
||||
logrus.Warnf("unable to remove %q from plugin remove: %v", pluginDir, err)
|
||||
|
||||
Reference in New Issue
Block a user