api to download artifacts

Litan
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 29, 2023

Is there any api to download pipeline artifacts. In my scenario I am generating an android .apk in one repo and trying to use this .apk in appium test which is in another repo.

1 answer

0 votes
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 29, 2023

Your pipeline is executed in a short-living Docker container which is dropped when the pipeline finishes. So if your artifacts are written to the container's filesystem, those will be lost.

We were a similar position like you, we needed to save the results of the pipeline and make downloadable by human users.

We did this:

  1. During the pipeline execution, after the artifacts are produced, we create Bitbucket downloads from those using the REST API. It is super-easy. We use a timestamp as suffix of the artifact's filename.
  2. Then if someone needs an artifact, he can go and download it any time.
  3. (Because we produce a lot of these artifacts, the pipeline will even delete those downloads that are older than N days, so we always have the artifacts produces in the last N days.)

It works fine and it has been stable for many years.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events