Artifacts


Artifacts

Transfer files between jobs using artifacts

All jobs in subsequent stages will receive the artifacts (by default)

Configuration

Name artifacts

Include and exclude paths

When to create artifacts (jobs success, failure, always)

Expire artifacts

Add untracked files

artifacts can be in default


Hands-On

Test binary in a new job and stage

  1. Create artifact from hello binary
  2. Add new stage called test
  3. Add new job in stage test
  4. Execute binary to test it

(See new .gitlab-ci.yml)


Dependencies

Jobs can restrict which job artifacts to receive

Add dependencies

job_name:
  dependencies:
  - other_job
  #...

Empty list disables receiving artifacts:

job_name:
  dependencies: []
  #...

Download artifact from another pipeline

See GitLab API