aboutsummaryrefslogtreecommitdiff
path: root/optee-build.yaml
blob: 62c3fcf43d824691a83a98f35ff48c051f26fa2e (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
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
- job:
    name: optee-build
    project-type: matrix
    defaults: global
    properties:
        - authorization:
            anonymous:
                - job-read
                - job-extended-read
                - job-workspace
            op-tee:
                - job-read
                - job-extended-read
                - job-build
                - job-cancel
                - job-configure
            linaro:
                - job-build
        - build-discarder:
            days-to-keep: 90
            num-to-keep: 90
    parameters:
        - string:
            name: PUB_DEST
            default: 'components/optee/build/${repo_proj}/${BUILD_NUMBER}'
        - string:
            name: LAVA_SERVER
            default: 'validation.linaro.org/RPC2/'
        - matrix-combinations:
            name: MATRIX_COMBINATIONS
    disabled: false
    node: master
    child-workspace: .
    display-name: 'OP-TEE Makefiles for various platforms'
    axes:
        - axis:
            type: slave
            name: label
            values:
                - docker-xenial-amd64
        - axis:
            type: user-defined
            name: repo_proj
            values:
                - default
                - fvp
                - hikey
                - juno
                - mt8173-evb
                - qemu_v8
                - rpi3
    scm:
        - git:
            url: https://github.com/OP-TEE/build.git
            refspec: +refs/heads/master:refs/remotes/origin/master
            name: origin
            branches:
                - refs/heads/master
            skip-tag: true
            shallow-clone: true
            wipe-workspace: false
    wrappers:
        - timestamps
        - build-name:
            name: '#${BUILD_NUMBER}-${GIT_REVISION,length=8}'
    builders:
        - shell:
            !include-raw: optee/build/builders.sh
        - linaro-publish-token
        - conditional-step:
            condition-kind: strings-match
            condition-string1: '${ENV,var="repo_proj"}'
            condition-string2: 'juno'
            steps:
                - shell:
                    !include-raw: optee/build/publishers.sh
                - shell:  |
                    #!/bin/bash

                    set -e

                    rm -rf configs
                    git clone --depth 1 http://git.linaro.org/ci/job/configs.git

                    DEVICE_TYPE=juno

                    sed -e "s|\${BUILD_NUMBER}|${BUILD_NUMBER}|" \
                        -e "s|\${BUILD_URL}|${BUILD_URL}|" \
                        -e "s|\${GIT_BRANCH}|${GIT_BRANCH}|" \
                        -e "s|\${GIT_COMMIT}|${GIT_COMMIT}|" \
                        -e "s|\${GIT_URL}|${GIT_URL}|" \
                        -e "s|\${PUBLISH_SERVER}|${PUBLISH_SERVER}|" \
                        -e "s|\${PUB_DEST}|${PUB_DEST}|" \
                        < configs/optee/build/lava-job-definitions/${DEVICE_TYPE}/template-optee-xtest.yaml \
                        > custom_lava_job_definition.yaml

                    cat << EOF > post_build_lava_parameters
                    DEVICE_TYPE=${DEVICE_TYPE}
                    CUSTOM_YAML_URL=${JOB_URL}/ws/custom_lava_job_definition.yaml
                    LAVA_SERVER=${LAVA_SERVER}
                    EOF
                - trigger-builds:
                    - project: 'post-build-lava'
                      property-file: post_build_lava_parameters
                      block: true