engine: add platform field to EngineConfig#669
engine: add platform field to EngineConfig#669TrevorBurnham wants to merge 1 commit intocontainers:mainfrom
Conversation
Luap99
left a comment
There was a problem hiding this comment.
Thanks
Please make podman and buildah Prs to actually implement that option so we know this will work before merging here.
Also this will have to be document in the default containers.conf file as well not just the mane page
|
As a general note the AI PR descriptions add nothing of value so just omit them, simply a short one sentence description with a link to the issue is enough for such a simple change |
41047e4 to
625a59a
Compare
|
@Luap99 Updated, thanks! |
When no --platform, --os, --arch, or --variant flags are specified, fall back to the platform value from containers.conf [engine] section. This allows users to set a default platform for all image operations (pull, build, from) without passing flags each time. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
Closes: containers#25641 Add support for setting a default platform for image operations (pull, build, create, run) without requiring --platform on every command. The default platform is resolved in the following priority order: 1. Explicit --platform (or --arch/--os) flag 2. DOCKER_DEFAULT_PLATFORM environment variable 3. containers.conf [engine] platform setting 4. Host's native OS/architecture This is useful for Apple Silicon users who need linux/amd64 images, and for Docker compatibility (DOCKER_DEFAULT_PLATFORM). Depends on: containers/container-libs#669 Signed-off-by: TrevorBurnham <TrevorBurnham@users.noreply.github.com> Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
|
I've submitted draft PRs for the downstream changes: |
Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
625a59a to
ebad6b0
Compare
Use go.podman.io/common from TrevorBurnham/container-libs#669 (add-engine-platform-config branch) to test the new engine platform config field in buildah CI. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
Replace go.podman.io/common, go.podman.io/image/v5, and go.podman.io/storage with TrevorBurnham/container-libs@add-engine-platform-config to test the new engine platform config field in buildah CI. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
When no --platform, --os, --arch, or --variant flags are specified, fall back to the platform value from containers.conf [engine] section. This allows users to set a default platform for all image operations (pull, build, from) without passing flags each time. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
Replace go.podman.io/common, go.podman.io/image/v5, and go.podman.io/storage with TrevorBurnham/container-libs@add-engine-platform-config to test the new engine platform config field in buildah CI. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
When no --platform, --os, --arch, or --variant flags are specified, fall back to the platform value from containers.conf [engine] section. This allows users to set a default platform for all image operations (pull, build, from) without passing flags each time. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
Replace go.podman.io/common, go.podman.io/image/v5, and go.podman.io/storage with TrevorBurnham/container-libs@add-engine-platform-config to test the new engine platform config field in buildah CI. Depends on: containers/container-libs#669 Signed-off-by: Trevor Burnham <trevorburnham@gmail.com>
|
Noting that the Buildah PR passed CI testing, Podman is still red tests there. |
|
Changes LGTM |
|
(The Podman PR points at a few design questions, at this point I wouldn’t rule out that we might want to change the syntax documented in this PR. But I’l leave that to experts.) |
I've rebased the branch and all checks for the PR are now passing except one, which appears to be due to a disruption in testing farm. |
Issue: containers/podman#25641
This PR adds a new
platformoption to the[engine]section ofcontainers.conf:This allows users to set a default platform (of the form
os/archoros/arch/variant) for image operations.