blob: 194769b4309ac97d51acdf4aefcf009ab49e3b57 [file] [log] [blame]
Paul Sokolovskya951a4c2023-06-01 21:34:09 +03001- job:
2 name: tf-a-lts2.8-builder
3 node: docker-amd64-tf-a-lts2.8-jammy
4 project-type: freestyle
5 concurrent: true
6 disabled: false
7 defaults: global
8 Description: |
9 Trusted Firmware A (TF-A) builder
10 properties:
11 - build-discarder:
12 days-to-keep: 15
13 artifact-num-to-keep: 40000
14 - authorization:
15 !include: authorization.yaml.inc
16 parameters:
17 - string:
18 name: import_cc
19 - string:
20 name: TEST_CONFIG
21 description: |
22 Original test configuration.
23 - string:
24 name: TEST_DESC
25 description: |
26 Expanded and normalized test configuration, aka "test description"
27 - string:
28 name: TF_GERRIT_PROJECT
29 default: 'TF-A/trusted-firmware-a'
30 - string:
31 name: TF_GERRIT_BRANCH
32 default: 'refs/heads/master'
33 - string:
34 name: TF_GERRIT_REFSPEC
35 default: '+refs/heads/master:refs/remotes/origin/master'
36 - string:
37 name: TFTF_GERRIT_PROJECT
38 default: 'TF-A/tf-a-tests'
39 - string:
40 name: TFTF_GERRIT_BRANCH
41 default: 'refs/heads/master'
42 - string:
43 name: TFTF_GERRIT_REFSPEC
44 default: '+refs/heads/master:refs/remotes/origin/master'
45 - string:
46 name: DOCKER_REGISTRY
47 default: '987685672616.dkr.ecr.us-east-1.amazonaws.com'
48 - string:
49 name: ARMLMD_LICENSE_FILE
50 default: '27000@flexnet.trustedfirmware.org'
51 - string:
52 name: JUNO_ROOTFS_URL
53 default: 'http://releases.linaro.org/openembedded/aarch64/17.01/linaro-image-minimal-genericarmv8-20170127-888.rootfs.tar.gz'
54 - string:
55 name: MBEDTLS_URL
56 default: 'https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-3.4.0.tar.gz'
57 - string:
58 name: GERRIT_PATCHSET_NUMBER
59 default: ''
60 - string:
61 name: GERRIT_CHANGE_NUMBER
62 default: ''
63 - string:
64 name: GERRIT_HOST
65 default: 'review.trustedfirmware.org'
66 - string:
67 name: QA_SERVER_TEAM
68 default: 'tf'
69 - string:
70 name: QA_SERVER_PROJECT
71 default: 'tf-a'
72 - string:
73 name: QA_SERVER_VERSION
74 default: ${BUILD_NUMBER}
75 - string:
76 name: QA_SERVER
77 default: 'https://qa-reports.linaro.org'
78 - string:
79 name: QA_TOOLS_REPO
80 default: 'https://git.gitlab.arm.com/tooling/qa-tools.git'
81 - string:
82 name: QA_TOOLS_BRANCH
83 default: 'master'
84 - string:
85 name: SHARE_FOLDER
86 default: '/srv/shared/${JOB_NAME}/${BUILD_NUMBER}'
87 description: 'Folder containing shared repositories for downstream pipeline jobs'
88 wrappers:
89 - timestamps
90 - timeout:
91 timeout: 120
92 fail: true
93 - credentials-binding:
94 - text:
95 credential-id: QA_REPORTS_TOKEN
96 variable: QA_REPORTS_TOKEN
97 - credentials-binding:
98 - text:
99 credential-id: LAVA_USER_TF
100 variable: LAVA_USER
101 - credentials-binding:
102 - text:
103 credential-id: LAVA_TOKEN_TF
104 variable: LAVA_TOKEN
105 builders:
106 - shell: |
107 aarch64-none-elf-gcc -v || true
108 - shell:
109 !include-raw: scripts/clone.sh
110 - shell:
111 !include-raw: tf-a-builder/builders.sh
112 - inject:
113 properties-file: artefacts/env
114 - shell: |
115 ln -s "artefacts/${BIN_MODE:-release}" "artefacts-lava"
116 - conditional-step:
117 condition-kind: file-exists
118 on-evaluation-failure: dont-run
119 condition-filename: artefacts-lava/job.yaml
120 condition-basedir: workspace
121 steps:
122 - shell: |
123 #!/bin/bash
124 set -e
125 DEVICE_TYPE=fvp
126 CUSTOM_YAML_URL=${BUILD_URL}/artifact/artefacts-lava/job.yaml
127 DEVICE_TYPE=$(awk -F': ' '/device_type/ {print $2}' ${WORKSPACE}/artefacts-lava/job.yaml)
128 cat << EOF > ${WORKSPACE}/lava.param
129 DEVICE_TYPE=${DEVICE_TYPE}
130 LAVA_SERVER=tf.validation.linaro.org
131 EOF
132 publishers:
133 - archive:
134 artifacts: artefacts/**, artefacts-lava/**
135 latest-only: false
136 allow-empty: true
137 - conditional-publisher:
138 - condition-kind: file-exists
139 on-evaluation-failure: dont-run
140 condition-filename: artefacts-lava/job.yaml
141 condition-basedir: workspace
142 action:
143 - postbuildscript:
144 mark-unstable-if-failed: true
145 builders:
146 - role: SLAVE
147 build-on:
148 - SUCCESS
149 build-steps:
150 - inject:
151 properties-file: ${WORKSPACE}/lava.param
152 - shell: |
153 #!/bin/bash
154
155 submit_job='tf-a-job-configs/tf-a-builder/submit-test-job.sh'
156 # FIXME: Juno and FVP jobs may fail due to non-related users changes,
157 # so CI needs to resubmit the job, at most three times:
158 # Juno jobs may fail due to LAVA lab infrastructure issues (see
159 # https://projects.linaro.org/browse/LSS-2128)
160 # FVP jobs may hang at some particular TFTF test (see
161 # https://linaro.atlassian.net/browse/TFC-176)
162 passed=0
163 for i in $(seq 1 3); do
164 echo "# LAVA submission iteration #$i"
165 if $submit_job; then
166 passed=1
167 break
168 fi
169 done
170 tf-a-job-configs/tf-a-builder/lava-log-process.sh
171 if [ $passed -eq 0 ]; then
172 echo "LAVA JOB RESULT: 1"
173 exit 1
174 else
175 echo "LAVA JOB RESULT: 0"
176 fi
177 - postbuildscript:
178 builders:
179 - role: SLAVE
180 build-on:
181 - SUCCESS
182 build-steps:
183 - shell: |
184 #!/bin/bash -e
185 echo "=== Starting expect-post tests ==="
186 ./tf-a-ci-scripts/script/expect-post-runner.sh
187 - conditional-publisher:
188 - condition-kind: file-exists
189 on-evaluation-failure: dont-run
190 condition-filename: lava-raw-debug.log
191 condition-basedir: workspace
192 action:
193 - archive:
194 artifacts: lava-raw-debug.log
195 latest-only: false
196 allow-empty: true
197 - archive:
198 artifacts: lava.log, lava-*.log, feedback.log, config_file.json, covtrace-*.log, trace_report/**
199 latest-only: false
200 allow-empty: true
201 - groovy-postbuild:
202 script:
203 !include-raw:
204 - tf-a-builder/postbuild.groovy