1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Fix docker system df when LCOW and WCOW images loaded

Signed-off-by: John Howard <jhoward@microsoft.com>
This commit is contained in:
John Howard 2018-08-22 15:29:18 -07:00
parent 7129bebe0a
commit 98380b1791

View file

@ -187,7 +187,15 @@ func (i *ImageService) Images(imageFilters filters.Args, all bool, withExtraAttr
// lazily init variables
if imagesMap == nil {
allContainers = i.containers.List()
allLayers = i.layerStores[img.OperatingSystem()].Map()
// allLayers is built from all layerstores combined
allLayers = make(map[layer.ChainID]layer.Layer)
for _, ls := range i.layerStores {
layers := ls.Map()
for k, v := range layers {
allLayers[k] = v
}
}
imagesMap = make(map[*image.Image]*types.ImageSummary)
layerRefs = make(map[layer.ChainID]int)
}