diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2018-05-03 08:59:19 -0400 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-05-03 13:12:46 +0000 |
commit | fae5033a01b78d3e8f23c1c9438bc5534dfe0fa3 (patch) | |
tree | e2a140a0493f23a8e3a1a6cfff04a826ef9fe12e /vendor/github.com/projectatomic/buildah/import.go | |
parent | e6ec1aaffe791a265ca7716813de47dacc4b70e8 (diff) | |
download | podman-fae5033a01b78d3e8f23c1c9438bc5534dfe0fa3.tar.gz podman-fae5033a01b78d3e8f23c1c9438bc5534dfe0fa3.tar.bz2 podman-fae5033a01b78d3e8f23c1c9438bc5534dfe0fa3.zip |
Make podman commit to localhost rather then docker.io
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Closes: #715
Approved by: mheon
Diffstat (limited to 'vendor/github.com/projectatomic/buildah/import.go')
-rw-r--r-- | vendor/github.com/projectatomic/buildah/import.go | 24 |
1 files changed, 9 insertions, 15 deletions
diff --git a/vendor/github.com/projectatomic/buildah/import.go b/vendor/github.com/projectatomic/buildah/import.go index b98219107..2a48d2c34 100644 --- a/vendor/github.com/projectatomic/buildah/import.go +++ b/vendor/github.com/projectatomic/buildah/import.go @@ -97,27 +97,21 @@ func importBuilder(ctx context.Context, store storage.Store, options ImportOptio } func importBuilderFromImage(ctx context.Context, store storage.Store, options ImportFromImageOptions) (*Builder, error) { - var img *storage.Image - var err error - if options.Image == "" { return nil, errors.Errorf("image name must be specified") } systemContext := getSystemContext(options.SystemContext, options.SignaturePolicyPath) - for _, image := range util.ResolveName(options.Image, "", systemContext, store) { - img, err = util.FindImage(store, image) - if err != nil { - continue - } - - builder, err2 := importBuilderDataFromImage(ctx, store, systemContext, img.ID, "", "") - if err2 != nil { - return nil, errors.Wrapf(err2, "error importing build settings from image %q", options.Image) - } + _, img, err := util.FindImage(store, "", systemContext, options.Image) + if err != nil { + return nil, errors.Wrapf(err, "error locating image %q for importing settings", options.Image) + } - return builder, nil + builder, err := importBuilderDataFromImage(ctx, store, systemContext, img.ID, "", "") + if err != nil { + return nil, errors.Wrapf(err, "error importing build settings from image %q", options.Image) } - return nil, errors.Wrapf(err, "error locating image %q for importing settings", options.Image) + + return builder, nil } |