Skip to content

feature request: add delay between --retry-times #2476

@xwu2intel

Description

@xwu2intel

This is my calling sequence:

ssh -4 <user>@<ip> -O ControlMaster=auto -fNL localhost:13340:localhost:20048     # localhost:20048 is the remote registry
skopeo copy --retry-times 10 --dest-tls-verify=false docker://<image> docker://localhost:13340/<image>
ssh -4 <user>@<ip> -O cancel -L localhost:13340:localhost:20048

As the remote registry is not directly accessible, I have to use ssh port forwarding as a bridge.

This works fine if there is no error during skopeo copy. If there is any error in the first try, then any subsequent retries will fail as well. This is because the remote registry is not immediately responding to subsequent connections, until after a time delay.

This following sequence works fine in the case of retries:

ssh -4 <user>@<ip> -O ControlMaster=auto -fNL localhost:13340:localhost:20048     # localhost:20048 is the remote registry
for retries in { 1..10 }; do
    skopeo copy --dest-tls-verify=false docker://<image> docker://<image> && break
    sleep 5s
done
ssh -4 <user>@<ip> -O cancel -L localhost:13340:localhost:20048

The request is to add time delay between retries.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions