summaryrefslogtreecommitdiff
path: root/cmd/podman
diff options
context:
space:
mode:
authorNalin Dahyabhai <nalin@redhat.com>2021-09-14 11:52:51 -0400
committerMatthew Heon <mheon@redhat.com>2021-09-16 11:00:05 -0400
commite07dccc3ad33c9018466b40056de5f002cd11271 (patch)
treed67868d65e6924c88e45b8169fcf06f098e483a8 /cmd/podman
parentc7c4cb886700823ba0f014e57e93faf450ac1241 (diff)
downloadpodman-e07dccc3ad33c9018466b40056de5f002cd11271.tar.gz
podman-e07dccc3ad33c9018466b40056de5f002cd11271.tar.bz2
podman-e07dccc3ad33c9018466b40056de5f002cd11271.zip
build: take advantage of --platform lists
The builder can take a list of platforms in the Platforms field of its BuildOptions argument, and we should definitely take advantage of that. The `bud-multiple-platform-values` test from buildah exercises support for this, so [NO TESTS NEEDED] Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Diffstat (limited to 'cmd/podman')
-rw-r--r--cmd/podman/images/build.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/cmd/podman/images/build.go b/cmd/podman/images/build.go
index 985cdf920..642da0c83 100644
--- a/cmd/podman/images/build.go
+++ b/cmd/podman/images/build.go
@@ -483,7 +483,7 @@ func buildFlagsWrapperToOptions(c *cobra.Command, contextDir string, flags *buil
runtimeFlags = append(runtimeFlags, "--systemd-cgroup")
}
- imageOS, arch, err := parse.PlatformFromOptions(c)
+ platforms, err := parse.PlatformsFromOptions(c)
if err != nil {
return nil, err
}
@@ -497,7 +497,6 @@ func buildFlagsWrapperToOptions(c *cobra.Command, contextDir string, flags *buil
AddCapabilities: flags.CapAdd,
AdditionalTags: tags,
Annotations: flags.Annotation,
- Architecture: arch,
Args: args,
BlobDirectory: flags.BlobCache,
CNIConfigDir: flags.CNIConfigDir,
@@ -523,11 +522,11 @@ func buildFlagsWrapperToOptions(c *cobra.Command, contextDir string, flags *buil
MaxPullPushRetries: 3,
NamespaceOptions: nsValues,
NoCache: flags.NoCache,
- OS: imageOS,
OciDecryptConfig: decConfig,
Out: stdout,
Output: output,
OutputFormat: format,
+ Platforms: platforms,
PullPolicy: pullPolicy,
PullPushRetryDelay: 2 * time.Second,
Quiet: flags.Quiet,