From 82dc15836b93b2fb528583e67170806a746a48db Mon Sep 17 00:00:00 2001 From: Kenfe-Mickael Laventure Date: Tue, 23 Aug 2016 16:19:37 -0700 Subject: [PATCH] Update Images() to allow retrieving specific image size data Those data include: - size of data shared with other images - size of data unique to a given image - how many containers are using a given image Signed-off-by: Kenfe-Mickael Laventure --- command/formatter/image.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/command/formatter/image.go b/command/formatter/image.go index 54cb7b62fa..39e05378c7 100644 --- a/command/formatter/image.go +++ b/command/formatter/image.go @@ -225,5 +225,6 @@ func (c *imageContext) CreatedAt() string { func (c *imageContext) Size() string { c.AddHeader(sizeHeader) - return units.HumanSizeWithPrecision(float64(c.i.Size), 3) + //NOTE: For backward compatibility we need to return VirtualSize + return units.HumanSizeWithPrecision(float64(c.i.VirtualSize), 3) }