-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
podman container runlabel should pull the image if it does not exist #7577
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: rhatdan The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@rhatdan lint isn't hip |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A nit and the request to keep the deprecation notification.
_ = flags.MarkHidden("signature-policy") | ||
|
||
if err := flags.MarkDeprecated("pull", "podman will pull if not found in local storage"); err != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please keep the flag deprecated. Otherwise, users using it won't be notified ("Flag --pull has been deprecated, podman will pull if not found in local storage") that it's a NOP.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added back
pkg/domain/infra/abi/images.go
Outdated
@@ -294,6 +294,10 @@ func (ir *ImageEngine) Pull(ctx context.Context, rawImage string, options entiti | |||
return &entities.ImagePullReport{Images: foundIDs}, nil | |||
} | |||
|
|||
func (ir *ImageEngine) Pull(ctx context.Context, rawImage string, options entities.ImagePullOptions) (*entities.ImagePullReport, error) { | |||
return pull(ir.Libpod.ImageRuntime(), ctx, rawImage, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change seems out of context of the bug fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The basic idea was to use one consistent way of pulling an image. I found bugs in the runlabel pull code, that were different then podman pull, so rather then cut and paste in the fixes, I created a new shared function that both could use.
Lint actually caught a bug. |
Since --pull is deprecated, remove it from help and hide if from --help Also set it to true by default. Share image pull code betweern podman image pull and podman container runlabel. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1877181 Signed-off-by: Daniel J Walsh <[email protected]>
LGTM |
LGTM |
/lgtm |
Since --pull is deprecated, remove it from help and hide if from --help
Also set it to true by default.
Share image pull code betweern podman image pull and podman container runlabel.
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1877181
Signed-off-by: Daniel J Walsh [email protected]