mirror of
https://github.com/clearlinux/docker.git
synced 2026-10-03 23:38:24 +00:00
added ability to iterate over all indexes and use index.Iterate() instead of ReadDir() to walk over the graph
Signed-off-by: Roman Strashkin <roman.strashkin@gmail.com>
This commit is contained in:
+1
-4
@@ -884,10 +884,7 @@ func (daemon *Daemon) ContainerGraph() *graphdb.Database {
|
||||
|
||||
func (daemon *Daemon) ImageGetCached(imgID string, config *runconfig.Config) (*graph.Image, error) {
|
||||
// Retrieve all images
|
||||
images, err := daemon.Graph().Map()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
images := daemon.Graph().Map()
|
||||
|
||||
// Store the tree in a map of map (map[parentId][childId])
|
||||
imageMap := make(map[string]map[string]struct{})
|
||||
|
||||
@@ -55,10 +55,7 @@ func (daemon *Daemon) imgDeleteHelper(name string, list *[]types.ImageDelete, fi
|
||||
tag = ""
|
||||
}
|
||||
|
||||
byParents, err := daemon.Graph().ByParent()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
byParents := daemon.Graph().ByParent()
|
||||
|
||||
repos := daemon.Repositories().ByID()[img.ID]
|
||||
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ import (
|
||||
)
|
||||
|
||||
func (daemon *Daemon) SystemInfo() (*types.Info, error) {
|
||||
images, _ := daemon.Graph().Map()
|
||||
images := daemon.Graph().Map()
|
||||
var imgcount int
|
||||
if images == nil {
|
||||
imgcount = 0
|
||||
|
||||
Reference in New Issue
Block a user