Fix copy when used with scratch and images with empty RootFS

Commit the rwLayer to get the correct DiffID
Refacator copy in thebuilder
move more code into exportImage
cleanup some windows tests
Release the newly commited layer.
Set the imageID on the buildStage after exporting a new image.
Move archiver to BuildManager.
Have ReleaseableLayer.Commit return a layer
and store the Image from exportImage in the local imageSources cache
Remove NewChild from image interface.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
This commit is contained in:
Daniel Nephin
2017-05-25 17:03:29 -04:00
parent ecd44d23cc
commit 5136096520
20 changed files with 319 additions and 180 deletions

View File

@@ -188,7 +188,7 @@ func (daemon *Daemon) Commit(name string, c *backend.ContainerCommitConfig) (str
Config: newConfig,
DiffID: l.DiffID(),
}
config, err := json.Marshal(parent.NewChild(cc))
config, err := json.Marshal(image.NewChildImage(parent, cc))
if err != nil {
return "", err
}