Skip to content

Conversation

@jankaluza
Copy link
Member

This commit adds new Retry= and RetryDelay= options to quadlet.go which result in --retry and --retry-delay usage in podman run command.

This allows configuring the retry logic in .container systemd files.

Fixes: #25109

Does this PR introduce a user-facing change?

The Retry= and RetryDelay= options are now supported in the systemd .container files.

Copy link
Member

@Luap99 Luap99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image and build units also should accept these options for consistency.

$ podman build --help | grep retry
      --retry int                                    number of times to retry in case of failure when performing push/pull (default 3)
      --retry-delay string                           delay between retries in case of push/pull failures
$ podman pull --help | grep retry
      --retry uint                   number of times to retry in case of failure when performing pull (default 3)
      --retry-delay string           delay between retries in case of pull failures

Copy link
Contributor

@ygalblum ygalblum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small doc nit

@jankaluza
Copy link
Member Author

image and build units also should accept these options for consistency.

$ podman build --help | grep retry
      --retry int                                    number of times to retry in case of failure when performing push/pull (default 3)
      --retry-delay string                           delay between retries in case of push/pull failures
$ podman pull --help | grep retry
      --retry uint                   number of times to retry in case of failure when performing pull (default 3)
      --retry-delay string           delay between retries in case of pull failures

Thanks, that's a good point. I've added them in the latest update :-).

@jankaluza
Copy link
Member Author

image and build units also should accept these options for consistency.

$ podman build --help | grep retry
      --retry int                                    number of times to retry in case of failure when performing push/pull (default 3)
      --retry-delay string                           delay between retries in case of push/pull failures
$ podman pull --help | grep retry
      --retry uint                   number of times to retry in case of failure when performing pull (default 3)
      --retry-delay string           delay between retries in case of pull failures

Thanks, that's a good point. I've added them in the latest update :-).

But checking that PR once more, I did not add documentation for them, will add it :-).

Copy link
Contributor

@ygalblum ygalblum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM, just missing the last doc part

This commit adds new Retry= and RetryDelay= options
to quadlet.go which result in --retry and --retry-delay
usage in podman run, image and build commands.

This allows configuring the retry logic in the systemd
files.

Fixes: containers#25109

Signed-off-by: Jan Kaluza <[email protected]>
@jankaluza
Copy link
Member Author

Added the documentation

Copy link
Member

@Luap99 Luap99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Mar 26, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 26, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jankaluza, Luap99

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 26, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 8d693d6 into containers:main Mar 26, 2025
80 of 81 checks passed
@stale-locking-app stale-locking-app bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Jun 25, 2025
@stale-locking-app stale-locking-app bot locked as resolved and limited conversation to collaborators Jun 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. release-note

Projects

None yet

Development

Successfully merging this pull request may close these issues.

quadlet (podman-systemd.unit) support for --retry and --retry-delay for image pulls

3 participants