Merge pull request #37802 from Microsoft/jjh/37687-docker-system-df
Fix docker system df when LCOW and WCOW images loaded
This commit is contained in:
commit
2bbd0bd8ef
1 changed files with 9 additions and 1 deletions
|
@ -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)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue