-
Notifications
You must be signed in to change notification settings - Fork 2
/
.gitlab-ci.yml
106 lines (97 loc) · 1.87 KB
/
.gitlab-ci.yml
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# vim: set ft=yaml sw=2:
stages:
- compliance
- lint
- build
- run
- test
- push
- npins
include:
- project: "helsinki-systems/gitlab-ci-templates"
ref: "master"
file:
# TODO: Use go/all.yml
- "common.yml"
default:
tags:
- nix
- helsinki-hydra-builder02
variables:
NIX_PATH: "nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixpkgs"
COMMIT_LOG: "1"
CI_COMMIT_MESSAGE: "Overwritten, because https://stackoverflow.com/questions/28865473/setting-environment-variable-to-a-large-value-argument-list-too-long#28865503"
CI_COMMIT_DESCRIPTION: "see above"
build:
stage: build
needs: []
when: always
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $COMMAND == "renovate"'
when: never
- when: always
script:
- ./ci/build
artifacts:
paths:
- ./wp4nix
run_full:
stage: run
needs:
- build
when: always
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $COMMAND == "run"'
artifacts:
paths:
- ./*.log
- ./*.json
script:
- ./ci/run
- ./ci/test
run_debug:
stage: run
needs:
- build
when: always
rules:
- if: '$CI_PIPELINE_SOURCE != "schedule"'
variables:
DEBUG: "1"
artifacts:
paths:
- ./*.log
- ./*.json
script:
- ./ci/run
- ./ci/test
test:
stage: test
needs: []
when: always
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $COMMAND == "renovate"'
when: never
- when: always
script:
- ./ci/test
push:
stage: push
needs:
- run_full
when: always
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $COMMAND == "run"'
script:
- ./ci/push
helsinki_npins:
stage: npins
needs:
- push
when: always
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $COMMAND == "run"'
trigger: helsinki-systems/helsinki
variables:
COMMAND: update_pin
PIN: wp4nix