xci: Configure daily job to use xci scripts
[releng.git] / jjb / xci / xci-daily-jobs.yml
1 #--------------------------------
2 # These jobs run on a daily basis and deploy OpenStack
3 # using the pinned versions of opnfv/releng, openstack/bifrost
4 # and openstack/openstack-ansible. Due to this, there is no
5 # version/branch is set/passed to jobs and instead the versions
6 # are checked out based on what is configured.
7 #--------------------------------
8 - project:
9     project: 'releng'
10
11     name: 'xci-daily'
12 #--------------------------------
13 # Branch Anchors
14 #--------------------------------
15     master: &master
16         stream: master
17         opnfv-releng-version: master
18         gs-pathname: ''
19     ocata: &ocata
20         stream: ocata
21         opnfv-releng-version: master
22         gs-pathname: '/{stream}'
23 #--------------------------------
24 # Scenarios
25 #--------------------------------
26     scenario:
27         - 'os-nosdn-nofeature-ha':
28             auto-trigger-name: 'daily-trigger-disabled'
29             xci-flavor: 'ha'
30         - 'os-nosdn-nofeature-noha':
31             auto-trigger-name: 'daily-trigger-disabled'
32             xci-flavor: 'noha'
33 #--------------------------------
34 # XCI PODs
35 #--------------------------------
36     pod:
37         - virtual:
38             <<: *master
39         - virtual:
40             <<: *ocata
41 #--------------------------------
42 # Supported Distros
43 #--------------------------------
44     distro:
45         - 'xenial':
46             disabled: false
47             slave-label: xci-xenial-virtual
48             dib-os-release: 'xenial'
49             dib-os-element: 'ubuntu-minimal'
50             dib-os-packages: 'vlan,vim,less,bridge-utils,sudo,language-pack-en,iputils-ping,rsyslog,curl,python,debootstrap,ifenslave,ifenslave-2.6,lsof,lvm2,tcpdump,nfs-kernel-server,chrony,iptabls'
51             extra-dib-elements: 'openssh-server'
52         - 'centos7':
53             disabled: true
54             slave-label: xci-centos7-virtual
55             dib-os-release: '7'
56             dib-os-element: 'centos7'
57             dib-os-packages: 'vim,less,bridge-utils,iputils,rsyslog,curl'
58             extra-dib-elements: 'openssh-server'
59         - 'suse':
60             disabled: true
61             slave-label: xci-suse-virtual
62             dib-os-release: '42.2'
63             dib-os-element: 'opensuse-minimal'
64             dib-os-packages: 'vim,less,bridge-utils,iputils,rsyslog,curl'
65             extra-dib-elements: 'openssh-server'
66
67 #--------------------------------
68 #        Phases
69 #--------------------------------
70     phase:
71         - 'deploy'
72         - 'functest'
73 #--------------------------------
74 # jobs
75 #--------------------------------
76     jobs:
77         - 'xci-{scenario}-{pod}-{distro}-daily-{stream}'
78         - 'xci-{phase}-{pod}-{distro}-daily-{stream}'
79
80 #--------------------------------
81 # job templates
82 #--------------------------------
83 - job-template:
84     name: 'xci-{scenario}-{pod}-{distro}-daily-{stream}'
85
86     disabled: '{obj:disabled}'
87
88     concurrent: false
89
90     properties:
91         - build-blocker:
92             use-build-blocker: true
93             blocking-jobs:
94                 - '^xci-os.*'
95                 - '^xci-deploy.*'
96                 - '^xci-functest.*'
97                 - '^bifrost-periodic-.*'
98                 - '^osa-periodic-.*'
99             block-level: 'NODE'
100         - logrotate-default
101
102     parameters:
103         - string:
104             name: DEPLOY_SCENARIO
105             default: '{scenario}'
106         - string:
107             name: XCI_FLAVOR
108             default: '{xci-flavor}'
109         - label:
110             name: SLAVE_LABEL
111             default: '{slave-label}'
112
113     triggers:
114         - '{auto-trigger-name}'
115
116     wrappers:
117         - fix-workspace-permissions
118
119     builders:
120         - description-setter:
121             description: "Built on $NODE_NAME"
122         - trigger-builds:
123             - project: 'xci-deploy-{pod}-{distro}-daily-{stream}'
124               current-parameters: false
125               predefined-parameters: |
126                 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
127                 XCI_FLAVOR=$XCI_FLAVOR
128               same-node: true
129               block: true
130         - trigger-builds:
131             - project: 'xci-functest-{pod}-{distro}-daily-{stream}'
132               current-parameters: false
133               predefined-parameters: |
134                 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
135                 XCI_FLAVOR=$XCI_FLAVOR
136               same-node: true
137               block: true
138               block-thresholds:
139                 build-step-failure-threshold: 'never'
140                 failure-threshold: 'never'
141                 unstable-threshold: 'FAILURE'
142
143     publishers:
144         - email:
145             recipients: fatih.degirmenci@ericsson.com yroblamo@redhat.com mchandras@suse.de jack.morgan@intel.com julienjut@gmail.com
146
147 - job-template:
148     name: 'xci-{phase}-{pod}-{distro}-daily-{stream}'
149
150     disabled: '{obj:disabled}'
151
152     concurrent: false
153
154     properties:
155         - build-blocker:
156             use-build-blocker: true
157             blocking-jobs:
158                 - '^xci-deploy.*'
159                 - '^xci-functest.*'
160                 - '^bifrost-periodic-.*'
161                 - '^osa-periodic-.*'
162             block-level: 'NODE'
163         - logrotate-default
164
165     wrappers:
166         - fix-workspace-permissions
167
168     scm:
169         - git-scm
170
171     parameters:
172         - project-parameter:
173             project: '{project}'
174             branch: '{opnfv-releng-version}'
175         - string:
176             name: DEPLOY_SCENARIO
177             default: 'os-nosdn-nofeature-ha'
178         - string:
179             name: XCI_FLAVOR
180             default: 'ha'
181         - string:
182             name: DISTRO
183             default: '{distro}'
184         - string:
185             name: DIB_OS_RELEASE
186             default: '{dib-os-release}'
187         - string:
188             name: DIB_OS_ELEMENT
189             default: '{dib-os-element}'
190         - string:
191             name: DIB_OS_PACKAGES
192             default: '{dib-os-packages}'
193         - string:
194             name: EXTRA_DIB_ELEMENTS
195             default: '{extra-dib-elements}'
196         - string:
197             name: CLEAN_DIB_IMAGES
198             default: 'true'
199         - label:
200             name: SLAVE_LABEL
201             default: '{slave-label}'
202         - string:
203             name: ANSIBLE_VERBOSITY
204             default: ''
205
206     builders:
207         - description-setter:
208             description: "Built on $NODE_NAME - Scenario: $DEPLOY_SCENARIO"
209         - 'xci-{phase}-builder'
210
211 #---------------------------
212 # builder macros
213 #---------------------------
214 - builder:
215     name: xci-deploy-builder
216     builders:
217         - shell:
218             !include-raw: ./xci-deploy.sh
219
220 - builder:
221     name: xci-functest-builder
222     builders:
223         - shell:
224             !include-raw: ./xci-functest.sh