mirror of
https://github.com/containers/buildah.git
synced 2025-04-18 07:04:05 +03:00
Podman adds an Error: to every error message. So starting an error message with "error" ends up being reported to the user as Error: error ... This patch removes the stutter. Also ioutil.ReadFile errors report the Path, so wrapping the err message with the path causes a stutter. Signed-off-by: Daniel J Walsh dwalsh@redhat.com [NO NEW TESTS NEEDED] Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
18 lines
412 B
Go
18 lines
412 B
Go
package buildah
|
|
|
|
import "fmt"
|
|
|
|
// Unmount unmounts a build container.
|
|
func (b *Builder) Unmount() error {
|
|
_, err := b.store.Unmount(b.ContainerID, false)
|
|
if err != nil {
|
|
return fmt.Errorf("unmounting build container %q: %w", b.ContainerID, err)
|
|
}
|
|
b.MountPoint = ""
|
|
err = b.Save()
|
|
if err != nil {
|
|
return fmt.Errorf("saving updated state for build container %q: %w", b.ContainerID, err)
|
|
}
|
|
return nil
|
|
}
|