diff options
author | Aditya R <arajan@redhat.com> | 2022-06-02 12:59:49 +0530 |
---|---|---|
committer | Aditya R <arajan@redhat.com> | 2022-06-02 17:38:33 +0530 |
commit | 44f11ec2c691b30f83af434556255638d16de42a (patch) | |
tree | 5f3038d71f06bf00c8a636a3f9333a58379d853d /pkg/bindings/images | |
parent | 516c95526ab68e4a6e13008d60d0156178c8571c (diff) | |
download | podman-44f11ec2c691b30f83af434556255638d16de42a.tar.gz podman-44f11ec2c691b30f83af434556255638d16de42a.tar.bz2 podman-44f11ec2c691b30f83af434556255638d16de42a.zip |
podman-remote: enable support for additional build-context on macOS, remote
Feature of additional build context added here https://github.com/containers/buildah/pull/3978
already exists on `podman` following PR just enables this feature of
`podman-remote` and `podman on macOS` setups.
Signed-off-by: Aditya R <arajan@redhat.com>
Diffstat (limited to 'pkg/bindings/images')
-rw-r--r-- | pkg/bindings/images/build.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/pkg/bindings/images/build.go b/pkg/bindings/images/build.go index b4b7c36f6..fe81dc662 100644 --- a/pkg/bindings/images/build.go +++ b/pkg/bindings/images/build.go @@ -81,6 +81,13 @@ func Build(ctx context.Context, containerFiles []string, options entities.BuildO for _, tag := range options.AdditionalTags { params.Add("t", tag) } + if additionalBuildContexts := options.AdditionalBuildContexts; len(additionalBuildContexts) > 0 { + additionalBuildContextMap, err := jsoniter.Marshal(additionalBuildContexts) + if err != nil { + return nil, err + } + params.Set("additionalbuildcontexts", string(additionalBuildContextMap)) + } if buildArgs := options.Args; len(buildArgs) > 0 { bArgs, err := jsoniter.MarshalToString(buildArgs) if err != nil { |