mirror of
https://github.com/containers/podman.git
synced 2025-06-26 04:46:57 +08:00
Add --all,-a flag to podman images
podman images will not show intermediate images by default. To view all images, including intermediate images created during a build, use the --all flag. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #947 Approved by: rhatdan
This commit is contained in:
@ -593,11 +593,11 @@ func (p *PodmanTest) GetContainerStatus() string {
|
||||
|
||||
// BuildImage uses podman build and buildah to build an image
|
||||
// called imageName based on a string dockerfile
|
||||
func (p *PodmanTest) BuildImage(dockerfile, imageName string) {
|
||||
func (p *PodmanTest) BuildImage(dockerfile, imageName string, layers string) {
|
||||
dockerfilePath := filepath.Join(p.TempDir, "Dockerfile")
|
||||
err := ioutil.WriteFile(dockerfilePath, []byte(dockerfile), 0755)
|
||||
Expect(err).To(BeNil())
|
||||
session := p.Podman([]string{"build", "-t", imageName, "--file", dockerfilePath, p.TempDir})
|
||||
session := p.Podman([]string{"build", "--layers=" + layers, "-t", imageName, "--file", dockerfilePath, p.TempDir})
|
||||
session.Wait(120)
|
||||
Expect(session.ExitCode()).To(Equal(0))
|
||||
}
|
||||
|
Reference in New Issue
Block a user