podman icon indicating copy to clipboard operation
podman copied to clipboard

fix podman build -o -

Open Napuu opened this issue 1 year ago • 8 comments

Ensure quiet flag is true when building directly to stdout.

Fixes #23063

Does this PR introduce a user-facing change?

Fixed podman build -o - to prevent status messages from appearing in stdout.

Napuu avatar Sep 09 '24 05:09 Napuu

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Napuu Once this PR has been reviewed and has the lgtm label, please assign lsm5 for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

openshift-ci[bot] avatar Sep 09 '24 05:09 openshift-ci[bot]

Ephemeral COPR build failed. @containers/packit-build please check.

This looks like it should be handled in the build options CLI?

https://github.com/containers/buildah/blob/main/pkg/cli/build.go#L267-L275

rhatdan avatar Sep 09 '24 12:09 rhatdan

The failed packit jobs for epel-9 and fedora-39 will go away after a rebase on main.

lsm5 avatar Sep 10 '24 11:09 lsm5

Test LGTM. Did you look into Dan's question? I think we should try to understand why the pkg/cli code is not having the desired effect, and fix it there. Would you be able to investigate that?

Also, for when you repush, these might be two good additions to your test:

		Expect(output).ShouldNot(ContainSubstring("STEP "))
		Expect(output).ShouldNot(ContainSubstring("COPY "))

edsantiago avatar Sep 10 '24 20:09 edsantiago

The mentioned code in Buildah isn't having the desired effect because that function is not used by Podman. A somewhat similar functionality is implemented in the function where I made my changes. Seems like it's already acknowledged that it shouldn't really be on Podman's side: https://github.com/containers/podman/blob/main/cmd/podman/common/build.go#L270

I think that would need a bigger refactoring to get rid of that duplicated part altogether.

Napuu avatar Sep 12 '24 05:09 Napuu

Can you change your PR to use said code in Buildah?

rhatdan avatar Sep 12 '24 09:09 rhatdan

Did some initial digging, and it doesn't seem as trivial as my previous change, so not for now at least.

I'll use buildah build -o - to achieve this for the time being. Might have time to investigate more in the future though.

Napuu avatar Sep 12 '24 18:09 Napuu

PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

openshift-merge-robot avatar Oct 07 '24 09:10 openshift-merge-robot