mirror of
https://github.com/clearlinux/docker.git
synced 2026-09-06 13:41:36 +00:00
improve aufs cleanup and debugging
This commit is contained in:
+17
-3
@@ -725,9 +725,23 @@ func NewRuntimeFromDirectory(config *DaemonConfig) (*Runtime, error) {
|
||||
}
|
||||
|
||||
func (runtime *Runtime) Close() error {
|
||||
runtime.networkManager.Close()
|
||||
runtime.driver.Cleanup()
|
||||
return runtime.containerGraph.Close()
|
||||
errorsStrings := []string{}
|
||||
if err := runtime.networkManager.Close(); err != nil {
|
||||
utils.Errorf("runtime.networkManager.Close(): %s", err.Error())
|
||||
errorsStrings = append(errorsStrings, err.Error())
|
||||
}
|
||||
if err := runtime.driver.Cleanup(); err != nil {
|
||||
utils.Errorf("runtime.driver.Cleanup(): %s", err.Error())
|
||||
errorsStrings = append(errorsStrings, err.Error())
|
||||
}
|
||||
if err := runtime.containerGraph.Close(); err != nil {
|
||||
utils.Errorf("runtime.containerGraph.Close(): %s", err.Error())
|
||||
errorsStrings = append(errorsStrings, err.Error())
|
||||
}
|
||||
if len(errorsStrings) > 0 {
|
||||
return fmt.Errorf("%s", strings.Join(errorsStrings, ", "))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (runtime *Runtime) Mount(container *Container) error {
|
||||
|
||||
Reference in New Issue
Block a user