fix volume driver deletions prevents recreation of volume issue
Signed-off-by: Wentao Zhang <zhangwentao234@huawei.com> Upstream-commit: 64d0592d41e96ac5c522c21d9270485e72c80231 Component: engine
This commit is contained in:
@ -269,7 +269,10 @@ func (s *VolumeStore) create(name, driverName string, opts, labels map[string]st
|
||||
if v.DriverName() != driverName && driverName != "" && driverName != volume.DefaultDriverName {
|
||||
return nil, errNameConflict
|
||||
}
|
||||
return v, nil
|
||||
// check exist in driver
|
||||
if driverName == "" || driverName == volume.DefaultDriverName {
|
||||
return v, nil
|
||||
}
|
||||
}
|
||||
|
||||
// Since there isn't a specified driver name, let's see if any of the existing drivers have this volume name
|
||||
|
||||
Reference in New Issue
Block a user