Merge "Upgrade to common-packer"
[ci-management.git] / jjb / ci-management / ci-management.yaml
1 ---
2 - project:
3     name: ci-management-jobs
4     jobs:
5       - '{project-name}-ci-jobs'
6
7     project: 'ci-management'
8     project-name: 'ci-management'
9     archive-artifacts: '**/*.log'
10     branch: 'master'
11     build-timeout: '60'
12     build-node: 'centos7-builder-2c-1g'
13     jjb-version: 2.0.0
14
15 - job-template:
16     name: '{project}-verify-jjb'
17
18     project-type: freestyle
19     node: '{build-node}'
20     concurrent: true
21
22     properties:
23       - infra-properties:
24           build-days-to-keep: 14
25
26     parameters:
27       - infra-parameters:
28           project: '{project}'
29           branch: 'master'
30           refspec: 'refs/heads/master'
31           artifacts: '{archive-artifacts}'
32
33     scm:
34       - gerrit-trigger-scm:
35           refspec: '$GERRIT_REFSPEC'
36           choosing-strategy: 'gerrit'
37           submodule-recursive: '{submodule-recursive}'
38
39     wrappers:
40       - infra-wrappers:
41           build-timeout: '{build-timeout}'
42
43     triggers:
44       - gerrit-trigger-patch-submitted:
45           server: '{server-name}'
46           project: '{project}'
47           branch: '{branch}'
48           files: 'jjb/**'
49
50     builders:
51       - config-file-provider:
52           files:
53             - file-id: 'jjbini'
54               variable: 'JJBINI'
55       - shell: |
56           virtualenv $WORKSPACE/venv
57           source $WORKSPACE/venv/bin/activate
58           pip install --upgrade pip
59           pip freeze
60           pip install jenkins-job-builder
61           jenkins-jobs -l DEBUG --conf $JJBINI test -o archives/job_output jjb/
62           gzip archives/job_output/*
63       - ci-management-check-unicode
64
65     publishers:
66       - infra-shiplogs:
67           maven-version: '{maven-version}'
68
69 - job-template:
70     name: '{project}-merge-jjb'
71
72     project-type: freestyle
73     node: '{build-node}'
74
75     properties:
76       - infra-properties:
77           build-days-to-keep: 14
78
79     parameters:
80       - infra-parameters:
81           project: '{project}'
82           branch: 'master'
83           refspec: 'refs/heads/master'
84           artifacts: '{archive-artifacts}'
85
86     scm:
87       - gerrit-trigger-scm:
88           refspec: ''
89           choosing-strategy: 'default'
90           submodule-recursive: '{submodule-recursive}'
91
92     wrappers:
93       - infra-wrappers:
94           build-timeout: '{build-timeout}'
95
96     triggers:
97       - gerrit-trigger-patch-merged:
98           server: '{server-name}'
99           project: '{project}'
100           branch: '{branch}'
101           files: 'jjb/**'
102
103     builders:
104       - config-file-provider:
105           files:
106             - file-id: 'jjbini'
107               variable: 'JJBINI'
108       - shell: |
109           virtualenv $WORKSPACE/venv
110           source $WORKSPACE/venv/bin/activate
111           pip install --upgrade pip
112           pip freeze
113           pip install jenkins-job-builder
114           jenkins-jobs --conf $JJBINI update --delete-old --workers 4 jjb/
115
116     publishers:
117       - infra-shiplogs:
118           maven-version: '{maven-version}'