GitLab Continuous Integration
GitLab Continuous Integration (CI) is used to automate some development tasks in the repository, most often for automatic unit testing. For the use of GitLab CI it is possible
configure your own physical or virtual machine (see
virtualization Stratus.FI ). In addition, a faculty machine can also be used
gitlab-ci.fi used official
GitLab Runner with container insulation in service
Docker . After starting a new task (eg after
git push to the repository) 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 mentioned file are started. When finished, the container is canceled and the result is returned to GitLab, which displays it in the
CI / CD section.
Project configuration for
The Docker is configured not to automatically install all required images, but to use only those locally available. This prevents excessive installation of different versions of images, which would quickly fill the disk capacity of the machine.
For a list of images available for the faculty GitLab CI, see application of the Faculty Administration .
The image used is declared in
.gitlab-ci.yml configuration as a key value
image . The format is either
REPOSITORY (The default tag is then used
latest ). If you do not enter an image, it will be used
If possible, use branded images
latest or at least the most general version possible (e.g.
3.5.0-jdk-8 ). If the images are updated, older versions will be deleted if there is not enough free disk space.
To prevent the machine from being burdened with tasks from repositories that have their own CI set up, it accepts
gitlab-ci.fi tasks only from those projects that are marked with the brand
shared-fi , which can be set as follows:
- in Settings → General → Permissions, enable the Pipelines option if it is not already enabled
- in settings
.gitlab-ci.ymladd a tag
shared-fito each target, eg:
build: tags: - shared-fi
You can look at the project in the faculty GitLab FI
unix/ci-examples for examples of CI configuration for simple projects.
Installing additional images
Request to install additional images or versions at
unixoNd0s3rhR@fikryRUxo8W.munivswfBC64I.cz where you specify what you will use the image for.
If you want to install your own or a customized image, attach the application with
Dockerfile and all the necessary files to build the image. Administrators build and install the image into Docker.