GitLab Continuous Integration
GitLab Continuous Integration (CI) is used to automate some repository development tasks, most commonly for automated unit testing. For use with GitLab CI can be
configure your own physical or virtual machine (see
Stratus.FI virtualization ). In addition, a faculty machine can also be used
gitlab-ci.fi used official
GitLab Runner with container insulation on duty
Docker . After starting a new task (e.g.
git push GitLab Runner asks Docker to create a new container from the image that is declared in the repository in the file
.gitlab-ci.yml . The repository is cloned into the container and the tasks described in the file are started. When finished, the container is dropped and the result is returned to GitLab, which displays it in the
CI / CD section.
Configuring the Project for
The docker is configured not to automatically install all required images, but to use only those locally available. This avoids over-installation of different versions of images that quickly fill up the disk capacity of the machine.
For a list of the images available for the GitLab CI faculty, see application of the Faculty Administration .
The image used is declared in
.gitlab-ci.yml configuration as the key value
image . The format is either
REPOSITORY (the default tag is then used
latest ). If no image is specified, it is used
If possible, use images with a mark
latest or at least the most general version (e.g.
3.5.0-jdk-8 ). In the case of image updates, older versions will be deleted if there is no free space on the disk.
The machine accepts tasks from repositories that have their own CI set
gitlab-ci.fi tasks only from those projects that are marked with a mark
shared-fi , which can be set as follows:
- in Settings → General → Permissions, enable Pipelines if it is not already enabled
- in settings
.gitlab-ci.ymladd a tag
shared-fito each goal, eg:
build: tags: - shared-fi
In the faculty GitLab FI you can look into the project
unix/ci-examples , where you will find CI configuration examples for simple projects.
Installing additional images
Ask to install additional images or versions at
unixGMTaKgL3x@fi0wmeUJ6P-.muniJIG5ikD6q.cz , specifying what the image will be used for.
If you want to install your own or customized image, please also include the application
Dockerfile and all the necessary files to build the image. Administrators build and install the image into Docker.