Skip to content

podman build --squash also squashes layers of base container #1234

Description

@mlschroe

Description

podman build --squash squashes all layers into a single layer, whereas docker build --squash only squashes the new layers but keeps the layers from the base container. Is this difference intentional? It IMHO limits the usefulness of the --squash option quite a bit.

Steps to reproduce the issue:

  1. podman build --squash

Describe the results you received:
The created container has only one layer.

Describe the results you expected:
The layers of the base container should be kept intact.

Output of rpm -q buildah or apt list buildah:

buildah-1.5-1.1.x86_64

Output of buildah version:

Version:         1.5
Go Version:      go1.11.1
Image Spec:      1.0.0
Runtime Spec:    1.0.0
CNI Spec:        0.4.0
libcni Version:  v0.7.0-alpha1
Git Commit:      87239ae7046ea3a25f644cd0789b3d6678dc144d
Built:           Fri Nov 23 12:00:00 2018
OS/Arch:         linux/amd64

Output of podman version if reporting a podman build issue:

Version:       0.11.1.1
Go Version:    go1.11.1
OS/Arch:       linux/amd64

Metadata

Metadata

Labels

from PodmanThis issue was either first reported on the Podman issue list or when running 'podman build'locked - please file new issue/PR

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions