Repository navigation
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
300 lines (272 loc) · 10.3 KB
/
Copy path.gitlab-ci.yml
File metadata and controls
300 lines (272 loc) · 10.3 KB
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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
###############################################################################
# Copyright (c) Lawrence Livermore National Security, LLC and other
# RAJA Project Developers. See top-level LICENSE and COPYRIGHT
# files for dates and other details. No copyright assignment is required
# to contribute to RAJA.
#
# SPDX-License-Identifier: (BSD-3-Clause)
###############################################################################
# DESCRIPTION:
###############################################################################
# General GitLab pipelines configurations for supercomputers and Linux clusters
# at Lawrence Livermore National Laboratory (LLNL).
# This entire pipeline is LLNL-specific
#
# This file uses GitLab CI Components from radiuss-shared-ci (requires GitLab 17.0+).
# Components provide better versioning, type-safe inputs, and cleaner syntax.
#
# In addition, each project should have:
# - .gitlab/custom-jobs.yml - Job templates for child pipelines
# - .gitlab/custom-variables.yml - Machine-specific variables
# - .gitlab/jobs/${CI_MACHINE}.yml - Machine-specific job definitions
###############################################################################
###############################################################################
# VARIABLES
###############################################################################
variables:
# LC GITLAB CONFIGURATION
# Use an LLNL service user to run CI. This prevents from running pipelines as
# an actual user.
LLNL_SERVICE_USER: rajasa
# Use the service user workspace. Solves permission issues, stores everything
# at the same location whoever triggers a pipeline.
# CUSTOM_CI_BUILDS_DIR: "/usr/workspace/rajasa/gitlab-runner"
# Optimize submodules usage: only fetch the ones we need.
# Note: We don't need to fetch dependencies handled by Spack.
GIT_SUBMODULE_STRATEGY: normal
GIT_SUBMODULE_DEPTH: 1
GIT_SUBMODULE_UPDATE_FLAGS: --jobs 3
GIT_SUBMODULE_PATHS: tpl/desul scripts/radiuss-spack-configs scripts/uberenv
# PROJECT VARIABLES
# This sha fixes the version of camp used in gitlab CI by RAJA
CAMP_REFERENCE: "b4edd077937245c120e25e6080be8caee5926347"
# SHARED_CI CONFIGURATION
# Required information about GitHub repository
GITHUB_PROJECT_NAME: "RAJA"
GITHUB_PROJECT_ORG: "LLNL"
# Set the build-and-test command.
# Nested variables are allowed and useful to customize the job command. We
# prevent variable expansion so that you can define them at job level.
JOB_CMD:
value: "./scripts/gitlab/build_and_test.sh"
expand: false
###############################################################################
# MAIN PIPELINE STAGES
###############################################################################
# IMPORTANT: You must define stages yourself to allow customization.
# The following stages are REQUIRED by RADIUSS Shared CI components:
stages:
- prerequisites # Required: machine availability checks
- build-and-test # Required: build and test jobs
- multi-project
###############################################################################
# INCLUDES
###############################################################################
include:
# Sets ID tokens for every job using `default:`
- project: 'lc-templates/id_tokens'
file: 'id_tokens.yml'
# Base pipeline templates and utilities
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/base-pipeline@2026.6.0
inputs:
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
github_token: $RSCI_GITHUB_STATUS_TOKEN
# Draft PR filter
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/utility-draft-pr-filter@2026.6.0
inputs:
github_token: $RSCI_GITHUB_STATUS_TOKEN
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
always_run_pattern: "^develop$|^main$|^v[0-9.]*-RC$"
# Local custom variables (used for component inputs and forwarded to child pipelines)
- local: '.gitlab/custom-variables.yml'
###############################################################################
# MACHINE PIPELINES
###############################################################################
# We organize the build-and-test stage with sub-pipelines. Each sub-pipeline
# corresponds to a test batch on a given machine.
#
# Note: .machine-check template is provided by the base-pipeline component
# and includes better error handling, validation, and GitHub status reporting.
# Trigger a build-and-test pipeline for each machine.
# Comment out the machine blocks you don't need.
# One job to generate the job list for all the subpipelines
generate-job-lists:
stage: prerequisites
tags: [shell, oslic]
variables:
RADIUSS_JOBS_PATH: "scripts/radiuss-spack-configs/gitlab/radiuss-jobs"
LOCAL_JOBS_PATH: ".gitlab/jobs"
script:
- cat ${RADIUSS_JOBS_PATH}/dane.yml ${LOCAL_JOBS_PATH}/dane.yml > dane-jobs.yml
- cat ${RADIUSS_JOBS_PATH}/matrix.yml ${LOCAL_JOBS_PATH}/matrix.yml > matrix-jobs.yml
- cat ${RADIUSS_JOBS_PATH}/corona.yml ${LOCAL_JOBS_PATH}/corona.yml > corona-jobs.yml
- cat ${RADIUSS_JOBS_PATH}/tioga.yml ${LOCAL_JOBS_PATH}/tioga.yml > tioga-jobs.yml
- cat ${RADIUSS_JOBS_PATH}/tuolumne.yml ${LOCAL_JOBS_PATH}/tuolumne.yml > tuolumne-jobs.yml
artifacts:
paths:
- dane-jobs.yml
- matrix-jobs.yml
- corona-jobs.yml
- tioga-jobs.yml
- tuolumne-jobs.yml
# DANE
dane-up-check:
extends: [.dane, .machine-check]
variables:
ASSOCIATED_CHILD_PIPELINE: "dane-build-and-test"
dane-build-and-test:
extends: [.dane, .build-and-test]
needs: [dane-up-check, generate-job-lists]
trigger:
include:
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/dane-pipeline@2026.6.0
inputs:
job_cmd: $JOB_CMD
shared_alloc: $DANE_SHARED_ALLOC
job_alloc: $DANE_JOB_ALLOC
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
- local: '.gitlab/custom-jobs.yml'
- artifact: 'dane-jobs.yml'
job: 'generate-job-lists'
# MATRIX
matrix-up-check:
extends: [.matrix, .machine-check]
variables:
ASSOCIATED_CHILD_PIPELINE: "matrix-build-and-test"
matrix-build-and-test:
extends: [.matrix, .build-and-test]
needs: [matrix-up-check, generate-job-lists]
trigger:
include:
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/matrix-pipeline@2026.6.0
inputs:
job_cmd: $JOB_CMD
shared_alloc: $MATRIX_SHARED_ALLOC
job_alloc: $MATRIX_JOB_ALLOC
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
- local: '.gitlab/custom-jobs.yml'
- artifact: 'matrix-jobs.yml'
job: 'generate-job-lists'
# CORONA
corona-up-check:
extends: [.corona, .machine-check]
variables:
ASSOCIATED_CHILD_PIPELINE: "corona-build-and-test"
corona-build-and-test:
extends: [.corona, .build-and-test]
needs: [corona-up-check, generate-job-lists]
trigger:
include:
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/corona-pipeline@2026.6.0
inputs:
job_cmd: $JOB_CMD
shared_alloc: $CORONA_SHARED_ALLOC
job_alloc: $CORONA_JOB_ALLOC
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
- local: '.gitlab/custom-jobs.yml'
- artifact: 'corona-jobs.yml'
job: 'generate-job-lists'
# TIOGA
tioga-up-check:
extends: [.tioga, .machine-check]
variables:
ASSOCIATED_CHILD_PIPELINE: "tioga-build-and-test"
tioga-build-and-test:
extends: [.tioga, .build-and-test]
needs: [tioga-up-check, generate-job-lists]
trigger:
include:
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/tioga-pipeline@2026.6.0
inputs:
job_cmd: $JOB_CMD
shared_alloc: $TIOGA_SHARED_ALLOC
job_alloc: $TIOGA_JOB_ALLOC
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
- local: '.gitlab/custom-jobs.yml'
- artifact: 'tioga-jobs.yml'
job: 'generate-job-lists'
# TUOLUMNE
tuolumne-up-check:
extends: [.tuolumne, .machine-check]
variables:
ASSOCIATED_CHILD_PIPELINE: "tuolumne-build-and-test"
tuolumne-build-and-test:
extends: [.tuolumne, .build-and-test]
needs: [tuolumne-up-check, generate-job-lists]
trigger:
include:
- component: $CI_SERVER_FQDN/radiuss/radiuss-shared-ci/tuolumne-pipeline@2026.6.0
inputs:
job_cmd: $JOB_CMD
shared_alloc: $TUOLUMNE_SHARED_ALLOC
job_alloc: $TUOLUMNE_JOB_ALLOC
github_project_name: $GITHUB_PROJECT_NAME
github_project_org: $GITHUB_PROJECT_ORG
- local: '.gitlab/custom-jobs.yml'
- artifact: 'tuolumne-jobs.yml'
job: 'generate-job-lists'
# MULTI-PROJECT PIPELINE
# In RAJA@develop CI pipelines, automatically test RAJAPerf, CHAI, and CARE
# against RAJA@develop.
#
# Otherwise, in regular CI pipelines, add manual trigger jobs to the pipeline.
# The trigger-<project> jobs test the current RAJA commit in RAJAPerf, CHAI or CARE.
#
# Set MULTI_PROJECT to "OFF" to disable all downstream pipeline triggers.
trigger-rajaperf:
stage: multi-project
rules:
- if: $MULTI_PROJECT != "OFF" && $CI_COMMIT_BRANCH == "develop"
when: on_success
allow_failure: true
- if: $MULTI_PROJECT != "OFF"
when: manual
allow_failure: true
- when: never
inherit:
variables: false
variables:
RAJA_REFERENCE: ${CI_COMMIT_SHA}
trigger:
project: radiuss/multi-project/rajaperf-trigger
branch: develop
trigger-chai:
stage: multi-project
rules:
- if: $MULTI_PROJECT != "OFF" && $CI_COMMIT_BRANCH == "develop"
when: on_success
allow_failure: true
- if: $MULTI_PROJECT != "OFF"
when: manual
allow_failure: true
- when: never
inherit:
variables: false
variables:
RAJA_REFERENCE: ${CI_COMMIT_SHA}
trigger:
project: radiuss/multi-project/chai-trigger
branch: develop
trigger-care:
stage: multi-project
rules:
- if: $MULTI_PROJECT != "OFF" && $CI_COMMIT_BRANCH == "develop"
when: on_success
allow_failure: true
- if: $MULTI_PROJECT != "OFF"
when: manual
allow_failure: true
- when: never
inherit:
variables: false
variables:
RAJA_REFERENCE: ${CI_COMMIT_SHA}
trigger:
project: radiuss/multi-project/care-trigger
branch: develop