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

URL to the latest successful artifact per task #663

Closed
sio opened this issue Jul 2, 2020 · 2 comments
Closed

URL to the latest successful artifact per task #663

sio opened this issue Jul 2, 2020 · 2 comments

Comments

@sio
Copy link

sio commented Jul 2, 2020

I'm trying to understand how to reliably access the latest artifacts generated by a particular task.

At first glance it seems straightforward (as per docs): https://api.cirrus-ci.com/v1/artifact/github/<USER OR ORGANIZATION>/<REPOSITORY>/<TASK NAME>/<ARTIFACTS NAME>/<PATH>.

But for more complex CI setup it turns out to be not so simple. If a more recent build for the same repo omits both the task that generated artifacts and *_artifacts instruction that saves the artifacts, the URL above will return 404 even though the artifacts are still there, they still are from the latest run of that task, just not from the latest build in this repo.

Example:

Is there a way to construct an URL that will always point to the latest artifacts of build-packer-image task even after completing some newer builds without that task?

@sio sio added the question label Jul 2, 2020
@fkorotkov
Copy link
Contributor

URLs are per build so if you use skip_if for some tasks than the latest URL won't work as you described. At the moment there is no way to have a link pointing to the latest run of a task.

@fkorotkov fkorotkov changed the title URL to the latest successful artifact: per build or per task? URL to the latest successful artifact per task Jul 3, 2020
@fkorotkov
Copy link
Contributor

We are not planning to add such links since it will break a contract that all artifacts from a link come from a single build.

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

No branches or pull requests

2 participants