-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
34 lines (32 loc) · 778 Bytes
/
.gitlab-ci.yml
File metadata and controls
34 lines (32 loc) · 778 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
stages:
- build
- trigger
jsonnet:
stage: build
tags:
- terraform
script:
- jsonnet gitlab-ci.jsonnet > generated-gitlab-ci.yml
rules:
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
- if: $CI_COMMIT_REF_NAME == $CI_DEFAULT_BRANCH
artifacts:
paths:
- generated-gitlab-ci.yml
trigger-tests:
stage: trigger
variables:
PIPELINE_SOURCE: $CI_PIPELINE_SOURCE
COMMIT_REF_NAME: $CI_COMMIT_REF_NAME
DEFAULT_BRANCH: $CI_DEFAULT_BRANCH
trigger:
include:
- local: $CI_PROJECT_DIR/child-tpl.yml
- artifact: generated-gitlab-ci.yml
job: jsonnet
strategy: depend
rules:
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
- if: $CI_COMMIT_REF_NAME == $CI_DEFAULT_BRANCH
needs:
- jsonnet