README.md 1.28 KB
Newer Older
Dominique Barton's avatar
Dominique Barton committed
1
2
3
4
5
Purpose
=======

This repository contains shared GitLab CI files which help to build and deploy stuff.

6
7
The advantages of shared CI files are documented in the [Development Guidelines](https://development-guidelines.confirm.ch/guidelines/gitlab_ci.html#shared-gitlab-ci-files).

Dominique Barton's avatar
Dominique Barton committed
8
9
10
11
12
Usage
=====

The CI files can be included via an `include` method like this:

Dominique Barton's avatar
Dominique Barton committed
13
```yaml
Dominique Barton's avatar
Dominique Barton committed
14
include:
15
16
  - project: confirm/gitlab-ci
    file: example.yml
Dominique Barton's avatar
Dominique Barton committed
17
18
19
```

If you want to know more about that feature, head over to the [.gitlab-ci.yml reference docs](https://docs.gitlab.com/ee/ci/yaml/README.html#include) or have a look at other [include examples](https://docs.gitlab.com/ee/ci/yaml/includes.html).
Dominique Barton's avatar
Dominique Barton committed
20

21
22
23
24
25
`SKIP_` Variables
=================

All GitLab CI files in this repository *should* implement the following `SKIP_*` variables:

26
- `SKIP_TEST`: Skip the test steps (**ONLY FOR EMERGENCIES**)
27
28
29
30
31
- `SKIP_BUILD`: Skip the build steps (and implicitly the deploy steps)
- `SKIP_DEPLOY`: Skip the deploy steps

This can be useful in scheduled pipeline runs, as you might only want to test stuff but no re-deploy it.

Dominique Barton's avatar
Dominique Barton committed
32
33
34
35
36
37
38
39
40
41
Linting
=======

The files will automatically be linted by the CI pipeline.

If you want to lint the files manually / locally, install [jq](https://stedolan.github.io/jq/) and run this command:

```bash
./lint-ci-files
```