ensure mount in commit

Upstream-commit: f385f1860bdebe2434bb122bd5ac8fec85687970
Component: engine
This commit is contained in:
Victor Vieux
2013-07-25 15:18:34 +00:00
parent f3125e247a
commit 2cfc902d29

View File

@ -124,6 +124,10 @@ func (builder *Builder) Create(config *Config) (*Container, error) {
func (builder *Builder) Commit(container *Container, repository, tag, comment, author string, config *Config) (*Image, error) {
// FIXME: freeze the container before copying it to avoid data corruption?
// FIXME: this shouldn't be in commands.
if err := container.EnsureMounted(); err != nil {
return nil, err
}
rwTar, err := container.ExportRw()
if err != nil {
return nil, err