# Robots: Gitlab CI

TRIGGER: ${GITLAB_CI}=true

Artifacts, patch logs, etc are configured to go to a yetus-out directory in the source tree after completion. Adding this stanza to your `.gitlab-ci.yml` file will upload and store those components for a week in Gitlab CI's artifact retrieval system:

    ---
      artifacts:
        expire_in: 1 week
        when: always
        paths:
          - yetus-out/

To use the pre-built Apache Yetus Docker image from docker hub as the build environment, use the following snippet in the `.gitlab-ci.yml` file, substituting the tag for the version of Apache Yetus that should be used and replacing the `JAVA_HOME` with the appropriate version as bundled mentioned in the Dockerfile:

    ---
    job:
      image: apache/yetus:0.9.0
      allow_failure: true
      variables:
        JAVA_HOME: /usr/lib/jvm/java-8-openjdk-amd64

      ...

See also:

- Apache Yetus' source tree .gitlab-ci.yml for some tips and tricks.