7 # -------------------------------
9 # -------------------------------
12 opnfv-releng-version: master
15 # -------------------------------
17 # -------------------------------
19 - 'os-nosdn-nofeature-noha':
20 deploy-scenario: 'os-nosdn-nofeature'
23 - 'os-nosdn-osm-noha':
24 deploy-scenario: 'os-nosdn-osm'
27 - 'os-odl-nofeature-noha':
28 deploy-scenario: 'os-odl-nofeature'
31 - 'os-odl-bgpvpn-noha':
32 deploy-scenario: 'os-odl-bgpvpn'
36 deploy-scenario: 'os-odl-sfc'
39 - 'k8-nosdn-nofeature-noha':
40 deploy-scenario: 'k8-nosdn-nofeature'
41 installer-type: 'kubespray'
43 - 'k8-canal-nofeature-noha':
44 deploy-scenario: 'k8-canal-nofeature'
45 installer-type: 'kubespray'
47 - 'k8-calico-nofeature-noha':
48 deploy-scenario: 'k8-calico-nofeature'
49 installer-type: 'kubespray'
51 - 'k8-contiv-nofeature-noha':
52 deploy-scenario: 'k8-contiv-nofeature'
53 installer-type: 'kubespray'
55 - 'k8-flannel-nofeature-noha':
56 deploy-scenario: 'k8-flannel-nofeature'
57 installer-type: 'kubespray'
59 - 'k8-nosdn-istio-noha':
60 deploy-scenario: 'k8-nosdn-istio'
61 installer-type: 'kubespray'
64 # -------------------------------
66 # -------------------------------
71 # -------------------------------
73 # -------------------------------
77 slave-label: xci-virtual
80 slave-label: xci-virtual
83 slave-label: xci-virtual
85 # -------------------------------
87 # -------------------------------
93 # -------------------------------
95 # -------------------------------
97 - 'xci-{scenario}-{pod}-{distro}-daily-{stream}'
98 - 'xci-{phase}-{pod}-{distro}-daily-{stream}'
100 # -------------------------------
102 # -------------------------------
104 name: 'xci-{scenario}-{pod}-{distro}-daily-{stream}'
106 disabled: '{obj:disabled}'
112 use-build-blocker: true
120 - '^bifrost-.*periodic.*'
121 - '^osa-.*periodic.*'
130 name: DEPLOY_SCENARIO
131 default: '{deploy-scenario}'
134 default: '{installer-type}'
137 default: '{xci-flavor}'
140 default: '{slave-label}'
145 name: FUNCTEST_VERSION
151 name: FUNCTEST_SUITE_NAME
158 default: https://gerrit.opnfv.org/gerrit/$PROJECT
159 description: 'Git URL to use on this Jenkins Slave'
165 - fix-workspace-permissions
168 - description-setter:
169 description: "Scenario: $DEPLOY_SCENARIO | Node: $NODE_NAME"
171 - project: 'xci-deploy-{pod}-{distro}-daily-{stream}'
172 current-parameters: false
173 predefined-parameters: |
174 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
175 INSTALLER_TYPE=$INSTALLER_TYPE
176 XCI_FLAVOR=$XCI_FLAVOR
178 XCI_DISTRO=$XCI_DISTRO
179 FUNCTEST_VERSION=$FUNCTEST_VERSION
180 FUNCTEST_MODE=$FUNCTEST_MODE
181 FUNCTEST_SUITE_NAME=$FUNCTEST_SUITE_NAME
185 - project: 'xci-functest-{pod}-{distro}-daily-{stream}'
186 current-parameters: false
187 predefined-parameters: |
188 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
189 INSTALLER_TYPE=$INSTALLER_TYPE
190 XCI_FLAVOR=$XCI_FLAVOR
192 XCI_DISTRO=$XCI_DISTRO
193 FUNCTEST_VERSION=$FUNCTEST_VERSION
194 FUNCTEST_MODE=$FUNCTEST_MODE
195 FUNCTEST_SUITE_NAME=$FUNCTEST_SUITE_NAME
199 build-step-failure-threshold: 'never'
200 failure-threshold: 'never'
201 unstable-threshold: 'FAILURE'
203 - project: 'xci-yardstick-{pod}-{distro}-daily-{stream}'
204 current-parameters: false
205 predefined-parameters: |
206 DEPLOY_SCENARIO=$DEPLOY_SCENARIO
207 INSTALLER_TYPE=$INSTALLER_TYPE
208 XCI_FLAVOR=$XCI_FLAVOR
210 XCI_DISTRO=$XCI_DISTRO
214 build-step-failure-threshold: 'never'
215 failure-threshold: 'never'
216 unstable-threshold: 'FAILURE'
219 # yamllint disable rule:line-length
220 # yamllint enable rule:line-length
221 - email-jenkins-admins-on-failure
224 name: 'xci-{phase}-{pod}-{distro}-daily-{stream}'
232 use-build-blocker: true
238 - '^bifrost-.*periodic.*'
239 - '^osa-.*periodic.*'
251 - fix-workspace-permissions
259 branch: '{opnfv-releng-version}'
261 name: DEPLOY_SCENARIO
262 default: 'os-nosdn-nofeature-noha'
274 default: '{slave-label}'
276 name: FUNCTEST_VERSION
282 name: FUNCTEST_SUITE_NAME
289 default: https://gerrit.opnfv.org/gerrit/$PROJECT
292 - description-setter:
293 description: "Scenario: $DEPLOY_SCENARIO | Node: $NODE_NAME"
294 - 'xci-daily-{phase}-macro'
296 # --------------------------
298 # --------------------------
299 # These need to be properly fixed once the basic deployment, functest, and
300 # yardstick jobs are working outside of clean vm.
301 # One of the ugly fixes is moving test preparation step into the
302 # deployment job itself since test preparation requires some of the
303 # things from deployment job. With clean VM, this wasn't an issue
304 # since everything was on clean VM. When we move things out of clean
305 # VM, things are done in workspaces of the jobs that are different.
307 # Apart from these things, we will need to go through the scripts
308 # used for verify jobs and make them updated in order to be able to
309 # use them for jobs that don't use clean VM.
311 name: 'xci-daily-deploy-macro'
318 echo "Cleaning the leftovers from the earlier run"
319 echo "---------------------------------------------------------------------------------"
320 for vm in $(sudo virsh list --all --name | grep -v xci_vm); do
322 sudo virsh destroy $vm > /dev/null 2>&1 || true
323 sudo virsh undefine $vm > /dev/null 2>&1 || true
324 sudo killall -r vbmc > /dev/null 2>&1 || true
325 sudo rm -rf /root/.vbmc > /dev/null 2>&1 || true
327 echo "---------------------------------------------------------------------------------"
329 cd $WORKSPACE/xci && ./xci-deploy.sh
331 echo "Prepare OPNFV VM for Tests"
332 echo "---------------------------------------------------------------------------------"
333 export XCI_PATH=$WORKSPACE
334 export XCI_VENV=${XCI_PATH}/venv
335 source $XCI_VENV/bin/activate
337 declare -x "\${var}" 2>/dev/null
339 done < ${XCI_PATH}/.cache/xci.env && cd ${XCI_PATH}/xci && \
340 ansible-playbook -i playbooks/dynamic_inventory.py \
341 -i ${XCI_PATH}/.cache/repos/openstack-ansible/inventory/dynamic_inventory.py \
342 playbooks/prepare-tests.yml
343 ssh root@192.168.122.2 "/root/prepare-tests.sh"
344 echo "---------------------------------------------------------------------------------"
347 name: 'xci-daily-functest-macro'
353 ssh root@192.168.122.2 "/root/run-functest.sh"
356 case ${DEPLOY_SCENARIO[0]} in
358 FUNCTEST_LOG=/root/functest-results/functest.log
361 FUNCTEST_LOG=/root/functest-results/functest-kubernetes.log
364 echo "Unable to determine the installer. Exiting!"
370 echo "---------------------------------------------------------------------------------"
371 ssh root@192.168.122.2 "cat $FUNCTEST_LOG"
372 echo "---------------------------------------------------------------------------------"
373 exit ${functest_exit}
375 name: 'xci-daily-yardstick-macro'
382 ssh root@192.168.122.2 "/root/run-yardstick.sh"