gitlab-download-artifacts
This Python utility is used to download artifacts from gitlab ci.
It can be used to grab artifacts from a CI job matching a git repo (or submodule) at the current commit, or from the https url of a repo, optionally at provided commit ref
gitlab-ci usage
When used in Gitlab CI a project / private token with api access will be required or user:pass specified in the url. Currently (Jan 2022) the CI Job Token doesn’t have enough api access to find the correct artifacts to download.
developer/desktop usage
If run from desktop the default browser will be used, however in this case an @<commit hash> cannot be used as the gitlab artifact urls don’t support this: https://docs.gitlab.com/ee/api/job_artifacts.html#download-the-artifacts-archive
gitlab-download-artifacts options
To download build artifacts for the current git project, simply run the tool from within the project folder and refer to the job whose artifacts are needed, eg:
cd myproject gitlab-download-artifacts . build
The artifacts from the build job are downloaded and extracted into the repo folder.
To download the artifacts for a submodule it can be used like:
gitlab-download-artifacts ./submodule build
The artifacts will be downloaded from the commit the submodule is checked out at and expanded into its folder.
Alternatively to just grab from a project page:
gitlab-download-artifacts https://gitlab.com/alelec/gitlab-download-artifacts@65ad5e1 release
Command Line
usage: gitlab-download-artifacts [-h] [-p PROJECT_TOKEN] [-t TIMEOUT] target job
Download gitlab artifacts
positional arguments:
target Path to git repo to grab or repo url (optionally with @<commit>)
job Gitlab CI job name to grab from
optional arguments:
-h, --help show this help message and exit
-p PROJECT_TOKEN, --project-token PROJECT_TOKEN Project / private token to auth with, env: ${PROJECT_TOKEN} by default
-t TIMEOUT, --timeout TIMEOUT Timeout (in minutes) to wait for dependent jobs to be ready
version: 1.4+g4a2cb1e
Metadata
Release files for gitlab-download-artifacts 1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gitlab_download_artifacts-1.4-py3-none-any.whl | Python 3 | none | any | Details for gitlab_download_artifacts-1.4-py3-none-any.whl |
Release files / gitlab_download_artifacts-1.4-py3-none-any.whl
| Download URL | gitlab_download_artifacts-1.4-py3-none-any.whl |
|---|---|
| Size | 6.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
02c0b32e183db61aef86e27f556280c55b94de47aeaf3ffeeaebe3768d49c490
|
|
BLAKE2b-256 checksum How to use checksums |
ddf92cc87ea94901fbdbedc255862a3d2947c74722e44f51583116656798d2cf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.12.1
|
Security for gitlab-download-artifacts 1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.