summaryrefslogtreecommitdiffstats
path: root/jjb
diff options
context:
space:
mode:
Diffstat (limited to 'jjb')
-rw-r--r--jjb/armband/armband-ci-jobs.yml2
-rw-r--r--jjb/container4nfv/yardstick-arm64.yml2
-rw-r--r--jjb/daisy4nfv/daisy-daily-jobs.yml21
-rw-r--r--jjb/daisy4nfv/daisy-project-jobs.yml7
-rw-r--r--jjb/doctor/doctor.yml39
-rwxr-xr-xjjb/functest/functest-alpine.sh4
-rw-r--r--jjb/functest/functest-daily-jobs.yml269
-rw-r--r--jjb/functest/functest-docker.yml (renamed from jjb/releng/functest-docker.yml)14
-rw-r--r--jjb/functest/xtesting-docker.yml221
-rw-r--r--jjb/global/releng-macros.yml24
-rw-r--r--jjb/global/slave-params.yml1
-rw-r--r--jjb/releng/opnfv-docker.yml9
-rw-r--r--jjb/xci/bifrost-verify-jobs.yml7
-rwxr-xr-xjjb/xci/xci-cleanup.sh8
-rw-r--r--jjb/xci/xci-daily-jobs.yml6
-rw-r--r--jjb/xci/xci-merge-jobs.yml10
-rwxr-xr-xjjb/xci/xci-promote.sh3
-rwxr-xr-xjjb/xci/xci-run-functest.sh12
-rwxr-xr-xjjb/xci/xci-set-scenario.sh193
-rwxr-xr-xjjb/xci/xci-start-deployment.sh3
-rwxr-xr-xjjb/xci/xci-start-new-vm.sh3
-rw-r--r--jjb/xci/xci-verify-jobs.yml14
22 files changed, 544 insertions, 328 deletions
diff --git a/jjb/armband/armband-ci-jobs.yml b/jjb/armband/armband-ci-jobs.yml
index ada430601..1c5f14880 100644
--- a/jjb/armband/armband-ci-jobs.yml
+++ b/jjb/armband/armband-ci-jobs.yml
@@ -131,7 +131,7 @@
same-node: true
block: true
- trigger-builds:
- - project: 'functest-{installer}-{pod}-daily-{stream}'
+ - project: 'functest-{installer}-{pod}-arm-daily-{stream}'
current-parameters: false
predefined-parameters:
DEPLOY_SCENARIO={scenario}
diff --git a/jjb/container4nfv/yardstick-arm64.yml b/jjb/container4nfv/yardstick-arm64.yml
index bd1d8aa85..03c68738a 100644
--- a/jjb/container4nfv/yardstick-arm64.yml
+++ b/jjb/container4nfv/yardstick-arm64.yml
@@ -5,7 +5,7 @@
- project:
name: yardstick-arm64
- project: '{name}'
+ project: 'yardstick'
# -------------------------------
# BRANCH ANCHORS
diff --git a/jjb/daisy4nfv/daisy-daily-jobs.yml b/jjb/daisy4nfv/daisy-daily-jobs.yml
index 6b1069362..453451f52 100644
--- a/jjb/daisy4nfv/daisy-daily-jobs.yml
+++ b/jjb/daisy4nfv/daisy-daily-jobs.yml
@@ -117,18 +117,7 @@
- '{installer}-defaults'
- '{slave-label}-defaults':
installer: '{installer}'
- - string:
- name: DEPLOY_SCENARIO
- default: '{scenario}'
- - string:
- name: INSTALLER_VERSION
- default: ''
- - string:
- name: UPSTREAM_JOB_NAME
- default: ''
- - string:
- name: UPSTREAM_BUILD_ID
- default: ''
+ - 'testapi-parameter'
- 'daisy-project-parameter':
gs-pathname: '{gs-pathname}'
@@ -201,8 +190,10 @@
- build-blocker:
use-build-blocker: true
blocking-jobs:
- - 'daisy.*-deploy-({pod})?-daily-.*'
- 'daisy-kolla-build-.*'
+ - '{installer}-daily-(build|deploy|test)-(euphrates|master)'
+ - '{installer}-.*-(baremetal|virtual|zte-pod9)-daily-(euphrates|master)'
+ - '(functest|yardstick)-{installer}-(baremetal|virtual|zte-pod9)-daily-(euphrates|master)'
block-level: 'NODE'
parameters:
@@ -212,9 +203,7 @@
- '{installer}-defaults'
- '{slave-label}-defaults':
installer: '{installer}'
- - string:
- name: DEPLOY_SCENARIO
- default: 'os-nosdn-nofeature-ha'
+ - 'testapi-parameter'
- 'daisy-project-parameter':
gs-pathname: '{gs-pathname}'
- string:
diff --git a/jjb/daisy4nfv/daisy-project-jobs.yml b/jjb/daisy4nfv/daisy-project-jobs.yml
index 006153f6f..c4edd7738 100644
--- a/jjb/daisy4nfv/daisy-project-jobs.yml
+++ b/jjb/daisy4nfv/daisy-project-jobs.yml
@@ -215,6 +215,13 @@
enabled: true
max-total: 6
option: 'project'
+ - build-blocker:
+ use-build-blocker: true
+ blocking-jobs:
+ - '{installer}-daily-(build|deploy|test)-(euphrates|master)'
+ - '{installer}-.*-(baremetal|virtual|zte-pod9)-daily-(euphrates|master)'
+ - '(functest|yardstick)-{installer}-(baremetal|virtual|zte-pod9)-daily-(euphrates|master)'
+ block-level: 'NODE'
scm:
- git-scm
diff --git a/jjb/doctor/doctor.yml b/jjb/doctor/doctor.yml
index ba76b8abb..8c04ffd53 100644
--- a/jjb/doctor/doctor.yml
+++ b/jjb/doctor/doctor.yml
@@ -19,7 +19,7 @@
installer:
- 'apex'
- 'fuel'
- # - 'joid'
+ - 'daisy'
arch:
- 'x86_64'
@@ -29,19 +29,17 @@
- 'sample'
- 'congress'
- task:
- - verify:
- auto-trigger-name: 'doctor-verify'
-
exclude:
- installer: 'apex'
arch: 'aarch64'
+ - installer: 'daisy'
+ arch: 'aarch64'
jobs:
- 'doctor-verify-{stream}'
- 'doctor-verify-unit-test-{stream}'
- - 'doctor-{task}-{inspector}-{stream}'
- - 'doctor-{task}-{installer}-{inspector}-{arch}-{stream}'
+ - 'doctor-verify-{inspector}-{stream}'
+ - 'doctor-verify-{installer}-{inspector}-{arch}-{stream}'
- job-template:
name: 'doctor-verify-{stream}'
@@ -76,6 +74,7 @@
file-paths:
- compare-type: ANT
pattern: 'doctor_tests/**'
+
builders:
- shell: |
#!/bin/bash
@@ -117,16 +116,17 @@
- 'doctor-verify-unit-test-publishers-macro'
- job-template:
- name: 'doctor-{task}-{inspector}-{stream}'
+ name: 'doctor-verify-{inspector}-{stream}'
disabled: '{obj:disabled}'
project-type: 'multijob'
scm:
- git-scm-gerrit
triggers:
- - '{auto-trigger-name}':
+ - 'doctor-verify':
project: '{project}'
branch: '{branch}'
files: 'doctor_tests/**'
+
builders:
- shell: |
#!/bin/bash
@@ -137,7 +137,7 @@
name: 'doctor-verify-apex-inspector'
execution-type: PARALLEL
projects:
- - name: 'doctor-{task}-apex-{inspector}-x86_64-{stream}'
+ - name: 'doctor-verify-apex-{inspector}-x86_64-{stream}'
predefined-parameters: |
PROJECT=$PROJECT
GERRIT_BRANCH=$GERRIT_BRANCH
@@ -151,7 +151,7 @@
name: 'doctor-verify-fuel-inspector'
execution-type: PARALLEL
projects:
- - name: 'doctor-{task}-fuel-{inspector}-x86_64-{stream}'
+ - name: 'doctor-verify-fuel-{inspector}-x86_64-{stream}'
predefined-parameters: |
PROJECT=$PROJECT
GERRIT_BRANCH=$GERRIT_BRANCH
@@ -165,7 +165,20 @@
name: 'doctor-verify-fuel-inspector'
execution-type: PARALLEL
projects:
- - name: 'doctor-{task}-fuel-{inspector}-aarch64-{stream}'
+ - name: 'doctor-verify-fuel-{inspector}-aarch64-{stream}'
+ predefined-parameters: |
+ GERRIT_BRANCH=$GERRIT_BRANCH
+ GERRIT_REFSPEC=$GERRIT_REFSPEC
+ GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+ GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+ kill-phase-on: FAILURE
+ current-parameters: true
+ git-revision: true
+ - multijob:
+ name: 'doctor-verify-daisy-inspector'
+ execution-type: PARALLEL
+ projects:
+ - name: 'doctor-verify-daisy-{inspector}-x86_64-{stream}'
predefined-parameters: |
PROJECT=$PROJECT
GERRIT_BRANCH=$GERRIT_BRANCH
@@ -177,7 +190,7 @@
git-revision: true
- job-template:
- name: 'doctor-{task}-{installer}-{inspector}-{arch}-{stream}'
+ name: 'doctor-verify-{installer}-{inspector}-{arch}-{stream}'
disabled: '{obj:disabled}'
node: 'doctor-{installer}-{arch}'
wrappers:
diff --git a/jjb/functest/functest-alpine.sh b/jjb/functest/functest-alpine.sh
index 541cc786c..432bbbb8b 100755
--- a/jjb/functest/functest-alpine.sh
+++ b/jjb/functest/functest-alpine.sh
@@ -177,9 +177,9 @@ if [[ ${DEPLOY_SCENARIO} =~ ^os-.* ]]; then
run_tiers ${tiers}
else
if [ ${DEPLOY_TYPE} == 'baremetal' ]; then
- tiers=(healthcheck smoke patrole features vnf parser)
+ tiers=(healthcheck smoke features vnf parser)
else
- tiers=(healthcheck smoke patrole features)
+ tiers=(healthcheck smoke features)
fi
run_tiers ${tiers}
fi
diff --git a/jjb/functest/functest-daily-jobs.yml b/jjb/functest/functest-daily-jobs.yml
index 23fc98173..a58e0bf3f 100644
--- a/jjb/functest/functest-daily-jobs.yml
+++ b/jjb/functest/functest-daily-jobs.yml
@@ -14,12 +14,10 @@
stream: master
branch: '{stream}'
gs-pathname: ''
- disabled: false
euphrates: &euphrates
stream: euphrates
branch: 'stable/{stream}'
gs-pathname: '/{stream}'
- disabled: false
# -------------------------------
# POD, INSTALLER, AND BRANCH MAPPING
# -------------------------------
@@ -195,115 +193,22 @@
# <<: *master
# -------------------------------
- functest-tier:
- - 'healthcheck':
- job-timeout: 20
- - 'smoke':
- job-timeout: 180
- - 'components':
- job-timeout: 240
- - 'patrole':
- job-timeout: 20
- - 'vnf':
- job-timeout: 240
- - 'parser':
- job-timeout: 20
-
- features-suite:
- - 'doctor-notification'
- - 'promise'
- - 'bgpvpn'
- - 'functest-odl-sfc'
- - 'domino-multinode'
- - 'fds'
- - 'barometercollectd'
-
- exclude:
- - features-suite: 'promise'
- stream: 'master'
- - features-suite: 'domino-multinode'
- stream: 'master'
- - features-suite: 'fds'
- stream: 'euphrates'
-
- build-job-settings: &build-job-settings
- current-parameter: false
- git-revision: true
- node-parameters: false
- kill-phase-on: FAILURE
- abort-all-jobs: false
- predefined-parameters: |
- FUNCTEST_MODE=$FUNCTEST_MODE
- FUNCTEST_TIER=$FUNCTEST_TIER
-
- features-job-settings: &features-job-settings
- current-parameter: false
- git-revision: true
- node-parameters: false
- kill-phase-on: FAILURE
- abort-all-jobs: false
- predefined-parameters: |
- FUNCTEST_MODE=$FUNCTEST_MODE
- FUNCTEST_SUITE_NAME=$FUNCTEST_SUITE_NAME
+ testsuite:
+ - 'suite':
+ job-timeout: 60
+ - 'daily':
+ job-timeout: 360
+ - 'arm-daily':
+ job-timeout: 360
jobs:
- - 'functest-{installer}-{pod}-suite-{stream}'
- - 'functest-{installer}-{pod}-daily-{stream}'
- - 'functest-{installer}-{pod}-daily-{functest-tier}-{stream}'
- - 'functest-{installer}-{pod}-daily-features-{features-suite}-{stream}'
+ - 'functest-{installer}-{pod}-{testsuite}-{stream}'
+
################################
# job template
################################
- job-template:
-
- name: 'functest-{installer}-{pod}-daily-{stream}'
-
- project-type: multijob
-
- disabled: '{obj:disabled}'
-
- parameters:
- - project-parameter:
- project: '{project}'
- branch: '{branch}'
- - '{installer}-defaults'
- - '{slave-label}-defaults'
- - functest-parameter:
- gs-pathname: '{gs-pathname}'
-
- builders:
- - multijob:
- name: 'Run functest tests'
- execution-type: SEQUENTIALLY
- projects:
- - name: 'functest-{installer}-{pod}-daily-healthcheck-{stream}'
- <<: *build-job-settings
- - name: 'functest-{installer}-{pod}-daily-smoke-{stream}'
- <<: *build-job-settings
- - name: 'functest-{installer}-{pod}-daily-patrole-{stream}'
- <<: *build-job-settings
- - name: 'functest-{installer}-{pod}-daily-vnf-{stream}'
- <<: *build-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-doctor-notification-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-bgpvpn-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-functest-odl-sfc-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-barometercollectd-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-fds-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-promise-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-features-domino-multinode-{stream}'
- <<: *features-job-settings
- - name: 'functest-{installer}-{pod}-daily-parser-{stream}'
- <<: *build-job-settings
-
-- job-template: &functest-installer-tier-job
-
- name: 'functest-{installer}-{pod}-daily-{functest-tier}-{stream}'
+ name: 'functest-{installer}-{pod}-{testsuite}-{stream}'
concurrent: true
@@ -327,96 +232,10 @@
branch: '{branch}'
- '{installer}-defaults'
- '{slave-label}-defaults'
- - string:
- name: FUNCTEST_MODE
- default: 'tier'
- - string:
- name: FUNCTEST_TIER
- default: '{functest-tier}'
- - string:
- name: DEPLOY_SCENARIO
- default: 'os-nosdn-nofeature-noha'
- - string:
- name: CLEAN_DOCKER_IMAGES
- default: 'false'
- description: 'Remove downloaded docker images (opnfv/functest*:*)'
- - functest-parameter:
- gs-pathname: '{gs-pathname}'
-
- scm:
- - git-scm
-
- builders:
- - description-setter:
- description: "Built on $NODE_NAME"
- - 'functest-daily-builder'
-
- publishers:
- - 'functest-recipients'
- - 'fuel-recipients'
-
-- job-template:
-
- name: 'functest-{installer}-{pod}-suite-{stream}'
- <<: *functest-installer-tier-job
-
- wrappers:
- - build-name:
- name: '$BUILD_NUMBER Suite: $FUNCTEST_MODE Scenario: $DEPLOY_SCENARIO'
- - timeout:
- timeout: '60'
- abort: true
- parameters:
- - project-parameter:
- project: '{project}'
- branch: '{branch}'
- - '{installer}-defaults'
- - '{slave-label}-defaults'
- - 'functest-suite-parameter'
- - string:
- name: DEPLOY_SCENARIO
- default: 'os-nosdn-nofeature-noha'
- - string:
- name: CLEAN_DOCKER_IMAGES
- default: 'false'
- description: 'Remove downloaded docker images (opnfv/functest*:*)'
- - functest-parameter:
- gs-pathname: '{gs-pathname}'
-
- builders:
- - description-setter:
- description: "Built on $NODE_NAME"
- - 'functest-suite-builder'
-
-- job-template:
-
- name: 'functest-{installer}-{pod}-daily-features-{features-suite}-{stream}'
- concurrent: true
- properties:
- - logrotate-default
- - throttle:
- enabled: true
- max-per-node: 1
- option: 'project'
- wrappers:
- - build-name:
- name: '$BUILD_NUMBER Suite: $FUNCTEST_MODE Scenario: $DEPLOY_SCENARIO'
-
- parameters:
- - project-parameter:
- project: '{project}'
- branch: '{branch}'
- - '{installer}-defaults'
- - '{slave-label}-defaults'
- - string:
- name: FUNCTEST_MODE
- default: 'testcase'
- - string:
- name: FUNCTEST_SUITE_NAME
- default: '{features-suite}'
+ - 'functest-{testsuite}-parameter'
- string:
name: DEPLOY_SCENARIO
- default: 'os-nosdn-nofeature-noha'
+ default: 'os-odl_l2-nofeature-ha'
- string:
name: CLEAN_DOCKER_IMAGES
default: 'false'
@@ -430,12 +249,7 @@
builders:
- description-setter:
description: "Built on $NODE_NAME"
- - 'functest-daily-builder'
-
- publishers:
- - 'functest-features-recipients'
- - 'functest-recipients'
- - 'fuel-recipients'
+ - 'functest-{testsuite}-builder'
########################
@@ -450,6 +264,14 @@
description: "Daily suite name to run"
- parameter:
+ name: functest-arm-daily-parameter
+ parameters:
+ - string:
+ name: FUNCTEST_MODE
+ default: 'arm-daily'
+ description: "Daily suite name (Aarch64) to run"
+
+- parameter:
name: functest-suite-parameter
parameters:
- choice:
@@ -473,7 +295,6 @@
- 'odl_netvirt'
- 'snaps_smoke'
- 'refstack_defcore'
- - 'patrole'
- 'promise'
- 'doctor'
- 'bgpvpn'
@@ -491,11 +312,9 @@
choices:
- 'healthcheck'
- 'smoke'
- - 'patrole'
- 'features'
- 'components'
- 'vnf'
- - 'parser'
default: 'healthcheck'
- string:
name: TESTCASE_OPTIONS
@@ -545,6 +364,14 @@
- 'functest-exit'
- builder:
+ name: functest-arm-daily-builder
+ builders:
+ - 'functest-cleanup'
+ - 'functest-arm-daily'
+ - 'functest-store-results'
+ - 'functest-exit'
+
+- builder:
name: functest-suite-builder
builders:
- 'functest-cleanup'
@@ -578,6 +405,17 @@
# yamllint enable rule:indentation
- builder:
+ name: functest-arm-daily
+ builders:
+ # yamllint disable rule:indentation
+ - shell:
+ !include-raw:
+ - ./functest-env-presetup.sh
+ - ../../utils/fetch_os_creds.sh
+ - ./functest-alpine.sh
+
+# yamllint enable rule:indentation
+- builder:
name: functest-store-results
builders:
- shell:
@@ -594,30 +432,3 @@
builders:
- shell:
!include-raw: ./functest-exit.sh
-
-
-- publisher:
- name: 'functest-features-recipients'
- publishers:
- - email:
- recipients:
-
-- publisher:
- name: 'functest-recipients'
- publishers:
- - email:
- recipients: >
- jalausuch@suse.com morgan.richomme@orange.com
- cedric.ollivier@orange.com feng.xiaowei@zte.com.cn
- juha.kosonen@nokia.com wangwulin@huawei.com
- delia.popescu@enea.com cristina.pauna@enea.com
- valentin.boucher@kontron.com
- - email-jenkins-admins-on-failure
-
-- publisher:
- name: 'fuel-recipients'
- publishers:
- - email:
- recipients: >
- peter.barabas@ericsson.com mpolenchuck@mirantis.com
- alexandru.avadanii@enea.com guillermo.herrero@enea.com
diff --git a/jjb/releng/functest-docker.yml b/jjb/functest/functest-docker.yml
index 7c576cf00..909c7b079 100644
--- a/jjb/releng/functest-docker.yml
+++ b/jjb/functest/functest-docker.yml
@@ -29,7 +29,6 @@
- 'features'
- 'components'
- 'parser'
- - 'patrole'
- 'smoke'
- 'vnf'
- 'restapi'
@@ -73,7 +72,7 @@
disabled: '{obj:disabled}'
parameters:
- - job-parameters:
+ - functest-job-parameters:
project: '{project}'
branch: '{branch}'
slave_label: 'opnfv-build-ubuntu'
@@ -129,10 +128,6 @@
<<: *build-job-settings
- name: 'functest-parser-docker-build-arm64-{stream}'
<<: *build-job-settings
- - name: 'functest-patrole-docker-build-amd64-{stream}'
- <<: *build-job-settings
- - name: 'functest-patrole-docker-build-arm64-{stream}'
- <<: *build-job-settings
- name: 'functest-smoke-docker-build-amd64-{stream}'
<<: *build-job-settings
- name: 'functest-smoke-docker-build-arm64-{stream}'
@@ -158,8 +153,6 @@
<<: *manifest-job-settings
- name: 'functest-parser-docker-manifest-{stream}'
<<: *manifest-job-settings
- - name: 'functest-patrole-docker-manifest-{stream}'
- <<: *manifest-job-settings
- name: 'functest-smoke-docker-manifest-{stream}'
<<: *manifest-job-settings
- name: 'functest-vnf-docker-manifest-{stream}'
@@ -175,7 +168,7 @@
name: 'functest-{image}-docker-build-{arch_tag}-{stream}'
disabled: '{obj:disabled}'
parameters:
- - job-parameters:
+ - functest-job-parameters:
project: '{project}'
branch: '{branch}'
slave_label: '{slave_label}'
@@ -237,7 +230,7 @@
# parameter macro
- parameter:
- name: job-parameters
+ name: functest-job-parameters
parameters:
- project-parameter:
project: '{project}'
@@ -297,3 +290,4 @@
jalausuch@suse.com morgan.richomme@orange.com
cedric.ollivier@orange.com feng.xiaowei@zte.com.cn
juha.kosonen@nokia.com wangwulin@huawei.com
+ valentin.boucher@kontron.com
diff --git a/jjb/functest/xtesting-docker.yml b/jjb/functest/xtesting-docker.yml
new file mode 100644
index 000000000..dc26344e3
--- /dev/null
+++ b/jjb/functest/xtesting-docker.yml
@@ -0,0 +1,221 @@
+---
+##############################################
+# job configuration for docker build and push
+##############################################
+- project:
+
+ name: xtesting-docker
+
+ project: functest-xtesting
+
+ stream:
+ - master:
+ branch: '{stream}'
+ disabled: false
+
+ arch_tag:
+ - 'amd64':
+ slave_label: 'opnfv-build-ubuntu'
+ - 'arm64':
+ slave_label: 'opnfv-build-ubuntu-arm'
+
+ # settings for jobs run in multijob phases
+ build-job-settings: &build-job-settings
+ current-parameters: false
+ git-revision: true
+ node-parameters: false
+ predefined-parameters: |
+ PUSH_IMAGE=$PUSH_IMAGE
+ COMMIT_ID=$COMMIT_ID
+ GERRIT_REFNAME=$GERRIT_REFNAME
+ DOCKERFILE=$DOCKERFILE
+ kill-phase-on: FAILURE
+ abort-all-jobs: false
+
+ manifest-job-settings: &manifest-job-settings
+ current-parameters: false
+ git-revision: true
+ node-parameters: false
+ predefined-parameters:
+ GERRIT_REFNAME=$GERRIT_REFNAME
+ kill-phase-on: FAILURE
+ abort-all-jobs: false
+
+ # yamllint enable rule:key-duplicates
+ jobs:
+ - "xtesting-docker-{stream}"
+ - "xtesting-docker-build-{arch_tag}-{stream}"
+ - "xtesting-docker-manifest-{stream}"
+
+########################
+# job templates
+########################
+- job-template:
+ name: 'xtesting-docker-{stream}'
+
+ project-type: multijob
+
+ disabled: '{obj:disabled}'
+
+ parameters:
+ - xtesting-job-parameters:
+ project: '{project}'
+ branch: '{branch}'
+ slave_label: 'opnfv-build-ubuntu'
+ arch_tag: 'amd64'
+
+ properties:
+ - throttle:
+ max-per-node: 1
+ option: 'project'
+
+ scm:
+ - git-scm
+
+ triggers:
+ - pollscm:
+ cron: "*/30 * * * *"
+ - gerrit-trigger-tag-created:
+ project: '{project}'
+
+ builders:
+ - multijob:
+ name: 'build xtesting images'
+ execution-type: PARALLEL
+ projects:
+ - name: 'xtesting-docker-build-amd64-{stream}'
+ <<: *build-job-settings
+ - name: 'xtesting-docker-build-arm64-{stream}'
+ <<: *build-job-settings
+ - multijob:
+ name: 'publish xtesting manifests'
+ execution-type: PARALLEL
+ projects:
+ - name: 'xtesting-docker-manifest-{stream}'
+ <<: *manifest-job-settings
+
+ publishers:
+ - 'xtesting-amd64-recipients'
+ - 'xtesting-arm64-recipients'
+
+- job-template:
+ name: 'xtesting-docker-build-{arch_tag}-{stream}'
+ disabled: '{obj:disabled}'
+ parameters:
+ - xtesting-job-parameters:
+ project: '{project}'
+ branch: '{branch}'
+ slave_label: '{slave_label}'
+ arch_tag: '{arch_tag}'
+ scm:
+ - git-scm
+ builders:
+ - shell: |
+ #!/bin/bash -ex
+ sudo arch={arch_tag} bash ./build.sh
+ exit $?
+
+- job-template:
+ name: 'xtesting-docker-manifest-{stream}'
+
+ parameters:
+ - project-parameter:
+ project: '{project}'
+ branch: '{branch}'
+ - label:
+ name: SLAVE_LABEL
+ default: 'opnfv-build-ubuntu'
+ description: 'Slave label on Jenkins'
+ - string:
+ name: PROJECT
+ default: "{project}"
+ description: "Project name used to enable job conditions"
+ - string:
+ name: GIT_BASE
+ default: https://gerrit.opnfv.org/gerrit/$PROJECT
+ description: 'Git URL to use on this Jenkins Slave'
+ - string:
+ name: REPO
+ default: "opnfv"
+ description: "Repository name for functest images"
+
+
+ disabled: '{obj:disabled}'
+
+ builders:
+ - shell: |
+ #!/bin/bash -ex
+ case "{stream}" in
+ "master")
+ tag="latest" ;;
+ *)
+ tag="{stream}" ;;
+ esac
+ sudo manifest-tool push from-args \
+ --platforms linux/amd64,linux/arm64 \
+ --template $REPO/xtesting:ARCH-$tag \
+ --target $REPO/xtesting:$tag
+ exit $?
+
+- parameter:
+ name: xtesting-job-parameters
+ parameters:
+ - project-parameter:
+ project: '{project}'
+ branch: '{branch}'
+ - label:
+ name: SLAVE_LABEL
+ default: '{slave_label}'
+ description: 'Slave label on Jenkins'
+ - string:
+ name: GIT_BASE
+ default: https://gerrit.opnfv.org/gerrit/$PROJECT
+ description: 'Git URL to use on this Jenkins Slave'
+ - string:
+ name: PUSH_IMAGE
+ default: "true"
+ description: "To enable/disable pushing the image to Dockerhub."
+ - string:
+ name: COMMIT_ID
+ default: ""
+ description: "commit id to make a snapshot docker image"
+ - string:
+ name: GERRIT_REFNAME
+ default: ""
+ description: "Docker tag to be built, e.g. refs/tags/5.0.0, refs/tags/opnfv-5.0.0, refs/tags/5.0.RC1"
+ - string:
+ name: DOCKERFILE
+ default: "Dockerfile"
+ description: "Dockerfile to use for creating the image."
+ - string:
+ name: ARCH_TAG
+ default: "{arch_tag}"
+ description: "If set, this value will be added to the docker image tag as a prefix"
+ - string:
+ name: PROJECT
+ default: "{project}"
+ description: "Project name used to enable job conditions"
+ - string:
+ name: REPO
+ default: "opnfv"
+ description: "Repository name for functest images"
+
+# publisher macros
+- publisher:
+ name: 'xtesting-arm64-recipients'
+ publishers:
+ - email:
+ recipients: >
+ cristina.pauna@enea.com
+ alexandru.avadanii@enea.com
+ delia.popescu@enea.com
+
+- publisher:
+ name: 'xtesting-amd64-recipients'
+ publishers:
+ - email:
+ recipients: >
+ jalausuch@suse.com morgan.richomme@orange.com
+ cedric.ollivier@orange.com feng.xiaowei@zte.com.cn
+ juha.kosonen@nokia.com wangwulin@huawei.com
+ valentin.boucher@kontron.com
diff --git a/jjb/global/releng-macros.yml b/jjb/global/releng-macros.yml
index 8f032345e..205802fab 100644
--- a/jjb/global/releng-macros.yml
+++ b/jjb/global/releng-macros.yml
@@ -39,10 +39,30 @@
name: GERRIT_REFSPEC
default: 'refs/heads/{branch}'
description: "Default refspec needed for manually triggering."
+
+- parameter:
+ name: testapi-parameter
+ parameters:
- string:
name: TESTAPI_URL
default: 'http://testresults.opnfv.org/test/api/v1'
description: "Default TestAPI URL, currently using v1"
+ - string:
+ name: DEPLOY_SCENARIO
+ default: 'os-nosdn-nofeature-ha'
+ description: "OPNFV deployment scenario"
+ - string:
+ name: INSTALLER_VERSION
+ default: 'master'
+ description: "Installer release version"
+ - string:
+ name: UPSTREAM_JOB_NAME
+ default: ''
+ description: "Parent job name in Jenkins"
+ - string:
+ name: UPSTREAM_BUILD_ID
+ default: ''
+ description: "Parent job build_id in Jenkins"
- property:
name: logrotate-default
@@ -966,7 +986,7 @@
- shell: |
echo "export PROVISION_RESULT=PASS" >> $WORKSPACE/installer_track.sh
echo "export INSTALLER=$INSTALLER_TYPE" >> $WORKSPACE/installer_track.sh
- echo "export TIMESTAMP_END="\'`date '+%Y-%m-%d %H:%M:%S.%3N'`\' > $WORKSPACE/installer_track.sh
+ echo "export TIMESTAMP_END="\'`date '+%Y-%m-%d %H:%M:%S.%3N'`\' >> $WORKSPACE/installer_track.sh
- shell:
!include-raw: installer-report.sh
- postbuildscript:
@@ -976,6 +996,6 @@
- shell: |
echo "export PROVISION_RESULT=FAIL" >> $WORKSPACE/installer_track.sh
echo "export INSTALLER=$INSTALLER_TYPE" >> $WORKSPACE/installer_track.sh
- echo "export TIMESTAMP_END="\'`date '+%Y-%m-%d %H:%M:%S.%3N'`\' > $WORKSPACE/installer_track.sh
+ echo "export TIMESTAMP_END="\'`date '+%Y-%m-%d %H:%M:%S.%3N'`\' >> $WORKSPACE/installer_track.sh
- shell:
!include-raw: installer-report.sh
diff --git a/jjb/global/slave-params.yml b/jjb/global/slave-params.yml
index 86b369bcd..6171a6abd 100644
--- a/jjb/global/slave-params.yml
+++ b/jjb/global/slave-params.yml
@@ -983,6 +983,7 @@
- 'doctor-fuel-x86_64'
- 'doctor-fuel-aarch64'
- 'doctor-joid-x86_64'
+ - 'doctor-daisy-x86_64'
- 'not-specified'
default-slaves:
- 'not-specified'
diff --git a/jjb/releng/opnfv-docker.yml b/jjb/releng/opnfv-docker.yml
index d0c2b2675..55cbc5f1d 100644
--- a/jjb/releng/opnfv-docker.yml
+++ b/jjb/releng/opnfv-docker.yml
@@ -91,6 +91,11 @@
dockerfile: 'docker/Dockerfile.local'
<<: *master
<<: *other-receivers
+ - 'qtip-nettest':
+ project: 'qtip'
+ dockerdir: 'contrib/nettest'
+ <<: *master
+ <<: *other-receivers
- 'storperf-master':
project: 'storperf'
dockerdir: 'docker/storperf-master'
@@ -176,10 +181,6 @@
project: 'yardstick'
<<: *euphrates
<<: *other-receivers
- - 'xtesting':
- project: 'functest-xtesting'
- <<: *master
- <<: *other-receivers
# projects with jobs for danube
- 'dovetail':
project: 'dovetail'
diff --git a/jjb/xci/bifrost-verify-jobs.yml b/jjb/xci/bifrost-verify-jobs.yml
index 7e0117565..2fb7c2167 100644
--- a/jjb/xci/bifrost-verify-jobs.yml
+++ b/jjb/xci/bifrost-verify-jobs.yml
@@ -162,6 +162,13 @@
recipients: fatih.degirmenci@ericsson.com yroblamo@redhat.com mchandras@suse.de jack.morgan@intel.com julienjut@gmail.com
# yamllint enable rule:line-length
- email-jenkins-admins-on-failure
+ - postbuildscript:
+ script-only-if-succeeded: false
+ script-only-if-failed: false
+ builders:
+ - shell:
+ !include-raw: ./xci-cleanup.sh
+
# -------------------------------
# trigger macros
# -------------------------------
diff --git a/jjb/xci/xci-cleanup.sh b/jjb/xci/xci-cleanup.sh
index ce84830aa..51a863da2 100755
--- a/jjb/xci/xci-cleanup.sh
+++ b/jjb/xci/xci-cleanup.sh
@@ -14,11 +14,15 @@
# what you are doing.
#----------------------------------------------------------------------
+# Need to cover macros with and without parameters
+VM_NAME=$DISTRO
+VM_NAME+=_xci_vm
+
# skip the deployment if the patch doesn't impact the deployment
if [[ "$GERRIT_TOPIC" =~ 'skip-verify' ]]; then
echo "Skipping the deployment!"
exit 0
fi
-sudo virsh destroy ${DISTRO}_xci_vm || true
-sudo virsh undefine ${DISTRO}_xci_vm || true
+sudo virsh destroy $VM_NAME || true
+sudo virsh undefine $VM_NAME || true
diff --git a/jjb/xci/xci-daily-jobs.yml b/jjb/xci/xci-daily-jobs.yml
index a92e49085..11db4e168 100644
--- a/jjb/xci/xci-daily-jobs.yml
+++ b/jjb/xci/xci-daily-jobs.yml
@@ -154,6 +154,12 @@
recipients: fatih.degirmenci@ericsson.com yroblamo@redhat.com mchandras@suse.de jack.morgan@intel.com julienjut@gmail.com
# yamllint enable rule:line-length
- email-jenkins-admins-on-failure
+ - postbuildscript:
+ script-only-if-succeeded: false
+ script-only-if-failed: false
+ builders:
+ - shell:
+ !include-raw: ./xci-cleanup.sh
- job-template:
name: 'xci-{phase}-{pod}-{distro}-daily-{stream}'
diff --git a/jjb/xci/xci-merge-jobs.yml b/jjb/xci/xci-merge-jobs.yml
index 492348d63..92eea190f 100644
--- a/jjb/xci/xci-merge-jobs.yml
+++ b/jjb/xci/xci-merge-jobs.yml
@@ -167,6 +167,14 @@
kill-phase-on: NEVER
abort-all-job: true
+ publishers:
+ - postbuildscript:
+ script-only-if-succeeded: false
+ script-only-if-failed: false
+ builders:
+ - shell:
+ !include-raw: ./xci-cleanup.sh
+
- job-template:
name: 'xci-{phase}-{type}-{distro}-merge-{stream}'
@@ -253,8 +261,6 @@
builders:
- shell:
!include-raw: ./xci-run-functest.sh
- - shell:
- !include-raw: ./xci-cleanup.sh
- builder:
name: 'xci-merge-promote-macro'
diff --git a/jjb/xci/xci-promote.sh b/jjb/xci/xci-promote.sh
index 98ad7ff4a..62818abee 100755
--- a/jjb/xci/xci-promote.sh
+++ b/jjb/xci/xci-promote.sh
@@ -14,6 +14,9 @@
# what you are doing.
#----------------------------------------------------------------------
+# ensure GERRIT_TOPIC is set
+GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+
# skip the healthcheck if the patch doesn't impact the deployment
if [[ "$GERRIT_TOPIC" =~ skip-verify|skip-deployment ]]; then
echo "Skipping the healthcheck!"
diff --git a/jjb/xci/xci-run-functest.sh b/jjb/xci/xci-run-functest.sh
index 9bcc469c7..60b48cf7f 100755
--- a/jjb/xci/xci-run-functest.sh
+++ b/jjb/xci/xci-run-functest.sh
@@ -7,6 +7,9 @@
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
+set -o errexit
+set -o nounset
+set -o pipefail
#----------------------------------------------------------------------
# This script is used by CI and executed by Jenkins jobs.
@@ -14,12 +17,21 @@
# what you are doing.
#----------------------------------------------------------------------
+# ensure GERRIT_TOPIC is set
+GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+
# skip the healthcheck if the patch doesn't impact the deployment
if [[ "$GERRIT_TOPIC" =~ skip-verify|skip-deployment ]]; then
echo "Skipping the healthcheck!"
exit 0
fi
+# skip the healthcheck if the scenario is Kubernetes scenario
+if [[ "$DEPLOY_SCENARIO" =~ k8 ]]; then
+ echo "Skipping the healthcheck!"
+ exit 0
+fi
+
# if the scenario is external, we need to wipe WORKSPACE to place releng-xci there since
# the project where the scenario is coming from is cloned and the patch checked out to the
# xci/scenarios/$DEPLOY_SCENARIO to be synched on clean VM
diff --git a/jjb/xci/xci-set-scenario.sh b/jjb/xci/xci-set-scenario.sh
index 764857ba4..62b26c019 100755
--- a/jjb/xci/xci-set-scenario.sh
+++ b/jjb/xci/xci-set-scenario.sh
@@ -8,7 +8,6 @@
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
set -o errexit
-set -o nounset
set -o pipefail
#----------------------------------------------------------------------
@@ -17,64 +16,176 @@ set -o pipefail
# what you are doing.
#----------------------------------------------------------------------
-WORK_DIRECTORY=/tmp/$GERRIT_CHANGE_NUMBER/$DISTRO
-/bin/rm -rf $WORK_DIRECTORY && mkdir -p $WORK_DIRECTORY
+# This function allows developers to specify the impacted scenario by adding
+# the info about installer and scenario into the commit message or using
+# the topic branch names. This results in either skipping the real verification
+# totally or skipping the determining the installer and scenario programmatically.
+# It is important to note that this feature is only available to generic scenarios
+# and only single installer/scenario pair is allowed.
+# The input in commit message should be placed at the end of the commit message body,
+# before the signed-off and change-id lines.
+#
+# Pattern to be searched in Commit Message
+# deploy-scenario:<scenario-name>
+# installer-type:<installer-type>
+# Examples:
+# deploy-scenario:os-odl-nofeature
+# installer-type:osa
+#
+# deploy-scenario:k8-nosdn-nofeature
+# installer-type:kubespray
+#
+# Patterns to be searched in topic branch name
+# skip-verify
+# skip-deployment
+# force-verify
+function override_generic_scenario() {
+ echo "Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC"
-# ensure GERRIT_TOPIC is set
-GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+ # process topic branch names
+ if [[ "$GERRIT_TOPIC" =~ skip-verify|skip-deployment ]]; then
+ # skip the real verification
+ echo "Skipping verify!"
+ echo "INSTALLER_TYPE=osa" > $WORK_DIRECTORY/scenario.properties
+ echo "DEPLOY_SCENARIO=os-nosdn-nofeature" >> $WORK_DIRECTORY/scenario.properties
+ exit 0
+ elif [[ "$GERRIT_TOPIC" =~ 'force-verify' ]]; then
+ # Run the deployment with default installer and scenario when multiple things change
+ # and we want to force that.
+ echo "Recording the installer 'osa' and scenario 'os-nosdn-nofeature' for downstream jobs"
+ echo "Forcing CI verification of default scenario and installer!"
+ echo "INSTALLER_TYPE=osa" > $WORK_DIRECTORY/scenario.properties
+ echo "DEPLOY_SCENARIO=os-nosdn-nofeature" >> $WORK_DIRECTORY/scenario.properties
+ exit 0
+ fi
-# skip the healthcheck if the patch doesn't impact the deployment
-if [[ "$GERRIT_TOPIC" =~ skip-verify|skip-deployment ]]; then
- echo "Skipping verify!"
- echo "DEPLOY_SCENARIO=os-nosdn-nofeature" > $WORK_DIRECTORY/scenario.properties
- exit 0
-fi
+ # process commit message
+ if [[ "$GERRIT_CHANGE_COMMIT_MESSAGE" =~ "installer-type:" && "$GERRIT_CHANGE_COMMIT_MESSAGE" =~ "deploy-scenario:" ]]; then
+ INSTALLER_TYPE=$(echo $GERRIT_CHANGE_COMMIT_MESSAGE | awk '/installer-type:/' RS=" " | cut -d":" -f2)
+ DEPLOY_SCENARIO=$(echo $GERRIT_CHANGE_COMMIT_MESSAGE | awk '/deploy-scenario:/' RS=" " | cut -d":" -f2)
+
+ if [[ -z "$INSTALLER_TYPE" || -z "$DEPLOY_SCENARIO" ]]; then
+ echo "Installer type or deploy scenario is not specified. Falling back to programmatically determining them."
+ else
+ echo "Recording the installer '$INSTALLER_TYPE' and scenario '$DEPLOY_SCENARIO' for downstream jobs"
+ echo "INSTALLER_TYPE=$INSTALLER_TYPE" > $WORK_DIRECTORY/scenario.properties
+ echo "DEPLOY_SCENARIO=$DEPLOY_SCENARIO" >> $WORK_DIRECTORY/scenario.properties
+ exit 0
+ fi
+ else
+ echo "Installer type or deploy scenario is not specified. Falling back to programmatically determining them."
+ fi
+}
-# if the scenario is external, we need to wipe WORKSPACE to place releng-xci there since
-# the project where the scenario is coming from is cloned and the patch checked out to the
-# xci/scenarios/$DEPLOY_SCENARIO to be synched on clean VM
-# apart from that, we need releng-xci stuff in WORKSPACE for things to function correctly on Jenkins.
-# if the change is coming to releng-xci, we don't need to do anything since the patch is checked
-# out to the WORKSPACE anyways
-if [[ $GERRIT_PROJECT != "releng-xci" ]]; then
+# This function determines the impacted generic scenario by processing the
+# change and using diff to see what changed. If changed files belong to a scenario
+# its name gets recorded for deploying and testing the right scenario.
+#
+# Pattern to be searched in Changeset
+# releng-xci/scenarios/<scenario>/<impacted files>: <scenario>
+# releng-xci/xci/installer/osa/<impacted files>: os-nosdn-nofeature
+# releng-xci/xci/installer/kubespray/<impacted files>: k8-nosdn-nofeature
+# the rest: os-nosdn-nofeature
+function determine_generic_scenario() {
+ echo "Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC"
+
+ # get the changeset
+ cd $WORKSPACE
+ CHANGESET=$(git diff HEAD^..HEAD --name-only)
+ for CHANGED_FILE in $CHANGESET; do
+ case $CHANGED_FILE in
+ *k8-nosdn*|*kubespray*)
+ [[ ${DEPLOY_SCENARIO[@]} =~ "k8-nosdn-nofeature" ]] || DEPLOY_SCENARIO[${#DEPLOY_SCENARIO[@]}]='k8-nosdn-nofeature'
+ ;;
+ *os-odl*)
+ [[ ${DEPLOY_SCENARIO[@]} =~ "os-odl-nofeature" ]] || DEPLOY_SCENARIO[${#DEPLOY_SCENARIO[@]}]='os-odl-nofeature'
+ ;;
+ *os-nosdn*|*osa*)
+ [[ ${DEPLOY_SCENARIO[@]} =~ "os-nosdn-nofeature" ]] || DEPLOY_SCENARIO[${#DEPLOY_SCENARIO[@]}]='os-nosdn-nofeature'
+ ;;
+ *)
+ [[ ${DEPLOY_SCENARIO[@]} =~ "os-nosdn-nofeature" ]] || DEPLOY_SCENARIO[${#DEPLOY_SCENARIO[@]}]='os-nosdn-nofeature'
+ ;;
+ esac
+ done
+}
+
+# This function determines the impacted external scenario by processing the Gerrit
+# change and using diff to see what changed. If changed files belong to a scenario
+# its name gets recorded for deploying and testing the right scenario.
+#
+# Pattern
+# <project-repo>/scenarios/<scenario>/<impacted files>: <scenario>
+function determine_external_scenario() {
+ echo "Processing $GERRIT_PROJECT patchset $GERRIT_REFSPEC"
+
+ # remove the clone that is done via jenkins and place releng-xci there so the
+ # things continue functioning properly
cd $HOME && /bin/rm -rf $WORKSPACE
- git clone https://gerrit.opnfv.org/gerrit/releng-xci $WORKSPACE && cd $WORKSPACE
+ git clone -q https://gerrit.opnfv.org/gerrit/releng-xci $WORKSPACE && cd $WORKSPACE
+
+ # fix the permissions so ssh doesn't complain due to having world-readable keyfiles
chmod -R go-rwx $WORKSPACE/xci/scripts/vm
-fi
-# if change is coming to releng-xci, continue as usual until that part is fixed as well
-if [[ $GERRIT_PROJECT == "releng-xci" ]]; then
- # save the scenario name into java properties file to be injected to downstream jobs via envInject
- echo "Recording scenario name for downstream jobs"
- echo "DEPLOY_SCENARIO=os-nosdn-nofeature" > $WORK_DIRECTORY/scenario.properties
- exit 0
-fi
+ # clone the project repo and fetch the patchset to process for further processing
+ git clone -q https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $WORK_DIRECTORY/$GERRIT_PROJECT
+ cd $WORK_DIRECTORY/$GERRIT_PROJECT
+ git fetch -q https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $GERRIT_REFSPEC && git checkout -q FETCH_HEAD
-# projects develop different scenarios and jobs need to know which scenario got the
-# change under test so the jobs can deploy and test the right scenario.
-# we need to fetch the change and look at the changeset to find out the scenario instead
-# of hardcoding scenario per project.
+ # process the diff to find out what scenario(s) are impacted - there should only be 1
+ DEPLOY_SCENARIO+=$(git diff HEAD^..HEAD --name-only | grep scenarios | awk -F '[/|/]' '{print $2}' | uniq)
+}
-git clone https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $WORK_DIRECTORY/$GERRIT_PROJECT
-cd $WORK_DIRECTORY/$GERRIT_PROJECT
-git fetch https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $GERRIT_REFSPEC && git checkout FETCH_HEAD
-DEPLOY_SCENARIO=$(git diff HEAD^..HEAD --name-only | grep scenarios | awk -F '[/|/]' '{print $2}' | uniq)
+echo "Determining the impacted scenario"
+
+declare -a DEPLOY_SCENARIO
+
+# ensure GERRIT_TOPIC is set
+GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+
+# this directory is where the temporary clones and files are created
+# while extracting the impacted scenario
+WORK_DIRECTORY=/tmp/$GERRIT_CHANGE_NUMBER/$DISTRO
+/bin/rm -rf $WORK_DIRECTORY && mkdir -p $WORK_DIRECTORY
+
+if [[ $GERRIT_PROJECT == "releng-xci" ]]; then
+ override_generic_scenario
+ determine_generic_scenario
+else
+ determine_external_scenario
+fi
# ensure single scenario is impacted
-if [[ $(echo $DEPLOY_SCENARIO | wc -w) != 1 ]]; then
+ if [[ $(IFS=$'\n' echo ${DEPLOY_SCENARIO[@]} | wc -w) != 1 ]]; then
echo "Change impacts multiple scenarios!"
echo "XCI doesn't support testing of changes that impact multiple scenarios currently."
echo "Please split your change into multiple different/dependent changes, each modifying single scenario."
exit 1
fi
-# save the scenario name into java properties file to be injected to downstream jobs via envInject
-echo "Recording scenario name '$DEPLOY_SCENARIO' for downstream jobs"
-echo "DEPLOY_SCENARIO=$DEPLOY_SCENARIO" > $WORK_DIRECTORY/scenario.properties
+# set the installer
+case ${DEPLOY_SCENARIO[0]} in
+ os-*)
+ INSTALLER_TYPE=osa
+ ;;
+ k8-*)
+ INSTALLER_TYPE=kubespray
+ ;;
+ *)
+ echo "Unable to determine the installer. Exiting!"
+ exit 1
+ ;;
+esac
+
+# save the installer and scenario names into java properties file
+# so they can be injected to downstream jobs via envInject
+echo "Recording the installer '$INSTALLER_TYPE' and scenario '${DEPLOY_SCENARIO[0]}' for downstream jobs"
+echo "INSTALLER_TYPE=$INSTALLER_TYPE" > $WORK_DIRECTORY/scenario.properties
+echo "DEPLOY_SCENARIO=$DEPLOY_SCENARIO" >> $WORK_DIRECTORY/scenario.properties
# skip the deployment if the scenario is not supported on this distro
OPNFV_SCENARIO_REQUIREMENTS=$WORKSPACE/xci/opnfv-scenario-requirements.yml
-if ! sed -n "/^- scenario: $DEPLOY_SCENARIO$/,/^$/p" $OPNFV_SCENARIO_REQUIREMENTS | grep -q $DISTRO; then
- echo "# SKIPPED: Scenario $DEPLOY_SCENARIO is NOT supported on $DISTRO"
+if ! sed -n "/^- scenario: ${DEPLOY_SCENARIO[0]}$/,/^$/p" $OPNFV_SCENARIO_REQUIREMENTS | grep -q $DISTRO; then
+ echo "# SKIPPED: Scenario ${DEPLOY_SCENARIO[0]} is NOT supported on $DISTRO"
exit 0
fi
diff --git a/jjb/xci/xci-start-deployment.sh b/jjb/xci/xci-start-deployment.sh
index 0628829ea..102ca41c3 100755
--- a/jjb/xci/xci-start-deployment.sh
+++ b/jjb/xci/xci-start-deployment.sh
@@ -14,6 +14,9 @@
# what you are doing.
#----------------------------------------------------------------------
+# ensure GERRIT_TOPIC is set
+GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+
# skip the deployment if the patch doesn't impact the deployment
if [[ "$GERRIT_TOPIC" =~ skip-verify|skip-deployment ]]; then
echo "Skipping the deployment!"
diff --git a/jjb/xci/xci-start-new-vm.sh b/jjb/xci/xci-start-new-vm.sh
index c2f1f991f..7874e6776 100755
--- a/jjb/xci/xci-start-new-vm.sh
+++ b/jjb/xci/xci-start-new-vm.sh
@@ -14,6 +14,9 @@
# what you are doing.
#----------------------------------------------------------------------
+# ensure GERRIT_TOPIC is set
+GERRIT_TOPIC="${GERRIT_TOPIC:-''}"
+
# skip the deployment if the patch doesn't impact the deployment
if [[ "$GERRIT_TOPIC" =~ 'skip-verify' ]]; then
echo "Skipping the deployment!"
diff --git a/jjb/xci/xci-verify-jobs.yml b/jjb/xci/xci-verify-jobs.yml
index c54a1b941..4c9ff9e69 100644
--- a/jjb/xci/xci-verify-jobs.yml
+++ b/jjb/xci/xci-verify-jobs.yml
@@ -188,6 +188,15 @@
kill-phase-on: NEVER
abort-all-job: true
+ publishers:
+ - postbuildscript:
+ script-only-if-succeeded: false
+ script-only-if-failed: false
+ builders:
+ - shell:
+ !include-raw: ./xci-cleanup.sh
+
+
- job-template:
name: 'xci-verify-{distro}-{phase}-{type}-{stream}'
@@ -229,9 +238,6 @@
name: OPNFV_RELENG_DEV_PATH
default: $WORKSPACE/
- string:
- name: INSTALLER_TYPE
- default: 'osa'
- - string:
name: GIT_BASE
default: https://gerrit.opnfv.org/gerrit/$PROJECT
description: 'Git URL to use on this Jenkins Slave'
@@ -275,5 +281,3 @@
builders:
- shell:
!include-raw: ./xci-run-functest.sh
- - shell:
- !include-raw: ./xci-cleanup.sh