Skip to content
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

Using put sometimes causes a Concourse job to fail due to the get task after pushing an image #278

Open
jonnydawg opened this issue May 6, 2021 · 4 comments

Comments

@jonnydawg
Copy link

I'm seeing an error like this sometimes when a Concourse worker runs a job that uses registry-image as a type.

fetching <repository>@sha256:<XXXXXXXXXXXXXXXXX>
ERRO[0000] fetching origin <image> failed: locate remote image: GET <repository>@sha256:<XXXXXXXXXXXXXXXXX>: NOT_FOUND: artifact <repository>@sha256:<XXXXXXXXXXXXXXXXX> not found 

Here is an example of what we are using:

- name: resource-name
  type: registry-image
  source:
    repository: <repository>
- put: resource-name

The image pushing will work successfully, but the secondary task of get when it pulls the image will fail randomly.

Is there a workaround for this?
Is it possible to disable the get that runs after the put task or to demand a sleep delay for the get task?

@vito
Copy link
Member

vito commented May 6, 2021

What type of registry is it pushing it to? Is it eventually consistent or something? Maybe get needs retry logic?

Is it possible to disable the get that runs after the put task or to demand a sleep delay for the get task?

Not currently possible, but will be possible in the future with resource prototypes (concourse/rfcs#38).

@jutkko
Copy link

jutkko commented Jun 2, 2021

We are hitting this in our pipelines as well (time wasted while getting the image). To work around this, do we explicitly upload the built image in a separate script?

@l00zak
Copy link

l00zak commented Sep 16, 2022

workaround is to set in your put step skip_download flag described here
https://concourse-ci.org/put-step.html#schema.put.get_params

@ericb-summit
Copy link

This is excellent, but what is the purpose of the implicit image fetch after the put? Seems odd to have this as a default behaviour?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants