mirror of
https://github.com/containers/skopeo.git
synced 2026-02-03 07:48:30 +00:00
Impove error reporting by wrapping all returned err functions with error.Wrapf Signed-off-by: Dan Walsh <dwalsh@redhat.com> Closes: #124 Approved by: nalind Signed-off-by: Dan Walsh <dwalsh@redhat.com> Closes: #125 Approved by: nalind
18 lines
408 B
Go
18 lines
408 B
Go
package buildah
|
|
|
|
import (
|
|
"github.com/pkg/errors"
|
|
)
|
|
|
|
// Delete removes the working container. The buildah.Builder object should not
|
|
// be used after this method is called.
|
|
func (b *Builder) Delete() error {
|
|
if err := b.store.DeleteContainer(b.ContainerID); err != nil {
|
|
return errors.Wrapf(err, "error deleting build container")
|
|
}
|
|
b.MountPoint = ""
|
|
b.Container = ""
|
|
b.ContainerID = ""
|
|
return nil
|
|
}
|