blob: 3c371ab1908fa52f859fd2d71c63e0ca5413e8b6 (
plain)
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
|
#include tcwg/default.yaml.inc
- job:
name: tcwg-report-stale-rr-jobs
project-type: freestyle
defaults: global
properties:
- default-properties
parameters:
- string:
name: days
default: 8
description: 'List jobs with no successful run in DAYS'
disabled: false
node: tcwg-coordinator
concurrent: false
display-name: 'TCWG CCC Report Stale RR Jobs'
scm:
- jenkins-scripts-master
triggers:
- timed: '@daily'
wrappers:
- timeout:
timeout: 300
- timestamps
- ssh-agent-credentials:
# tcwg-buildslave user id
users:
- 'e0958a95-204f-4c14-a66c-5e2be6c5d50a'
builders:
- shell: |
#!/bin/bash
set -euf -o pipefail
set -x
rm -rf artifacts
mkdir artifacts
bash -x ./jenkins-scripts/tcwg-report-stale-rr-jobs.sh --days "$days" \
--output artifacts/stale-jobs.log
bash -x ./jenkins-scripts/tcwg-report-stale-rr-jobs.sh \
--classify artifacts/stale-jobs.log \
--output artifacts/stale-jobs-analysis.log || true
n_lines=$(cat artifacts/stale-jobs.log | wc -l)
./jenkins-scripts/tcwg-report-ci-status.sh > artifacts/ci-status.log
if [ x"$n_lines" != x"0" ]; then
(
echo "Jobs with no new results in $days days ($n_lines entries):"
cat artifacts/ci-status.log
cat artifacts/stale-jobs-analysis.log
cat artifacts/stale-jobs.log
) > artifacts/email-body.txt
exit 1
fi
publishers:
- archive:
artifacts: 'artifacts/**'
latest-only: false
- email-ext:
recipients: 'maxim.kuvyrkov@linaro.org, laurent.alfonsi@linaro.org'
content-type: text
body: |
${FILE,path="artifacts/email-body.txt"}
failure: true
aborted: true
|