diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-03-29 17:14:26 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-29 17:14:26 +0000 |
commit | 26b0ebd22f0a516eae9daf2439697f1f793894cc (patch) | |
tree | ee369f8ec30af3b74d29787e43799b2fb7eed8f9 /pkg/api/handlers/compat/images_build.go | |
parent | b7bb8a1fb942a0568a1ff257798702bd0cde5d37 (diff) | |
parent | 127400880a1a3d53d4d4eb454cc9f35ddc89e79a (diff) | |
download | podman-26b0ebd22f0a516eae9daf2439697f1f793894cc.tar.gz podman-26b0ebd22f0a516eae9daf2439697f1f793894cc.tar.bz2 podman-26b0ebd22f0a516eae9daf2439697f1f793894cc.zip |
Merge pull request #9516 from rhatdan/shrink
[NO TESTS NEEDED] Shrink the size of podman bindings
Diffstat (limited to 'pkg/api/handlers/compat/images_build.go')
-rw-r--r-- | pkg/api/handlers/compat/images_build.go | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/pkg/api/handlers/compat/images_build.go b/pkg/api/handlers/compat/images_build.go index 36785a362..fd310711f 100644 --- a/pkg/api/handlers/compat/images_build.go +++ b/pkg/api/handlers/compat/images_build.go @@ -13,8 +13,7 @@ import ( "time" "github.com/containers/buildah" - "github.com/containers/buildah/define" - "github.com/containers/buildah/imagebuildah" + buildahDefine "github.com/containers/buildah/define" "github.com/containers/buildah/util" "github.com/containers/image/v5/types" "github.com/containers/podman/v3/libpod" @@ -277,13 +276,13 @@ func BuildImage(w http.ResponseWriter, r *http.Request) { jobs = query.Jobs } - pullPolicy := define.PullIfMissing + pullPolicy := buildahDefine.PullIfMissing if utils.IsLibpodRequest(r) { - pullPolicy = define.PolicyMap[query.PullPolicy] + pullPolicy = buildahDefine.PolicyMap[query.PullPolicy] } else { if _, found := r.URL.Query()["pull"]; found { if query.Pull { - pullPolicy = define.PullAlways + pullPolicy = buildahDefine.PullAlways } } } @@ -315,7 +314,7 @@ func BuildImage(w http.ResponseWriter, r *http.Request) { utils.Error(w, "Something went wrong.", http.StatusInternalServerError, errors.Wrap(err, "Decode()")) return } - buildOptions := imagebuildah.BuildOptions{ + buildOptions := buildahDefine.BuildOptions{ AddCapabilities: addCaps, AdditionalTags: additionalTags, Annotations: annotations, |