diff options
Diffstat (limited to 'jjb/3rd_party_ci')
-rwxr-xr-x | jjb/3rd_party_ci/create-apex-vms.sh | 12 | ||||
-rwxr-xr-x | jjb/3rd_party_ci/detect-snapshot.sh | 30 | ||||
-rwxr-xr-x | jjb/3rd_party_ci/download-netvirt-artifact.sh | 38 | ||||
-rwxr-xr-x | jjb/3rd_party_ci/install-netvirt.sh | 32 | ||||
-rw-r--r-- | jjb/3rd_party_ci/odl-netvirt.yaml | 287 | ||||
-rwxr-xr-x | jjb/3rd_party_ci/postprocess-netvirt.sh | 11 |
6 files changed, 0 insertions, 410 deletions
diff --git a/jjb/3rd_party_ci/create-apex-vms.sh b/jjb/3rd_party_ci/create-apex-vms.sh deleted file mode 100755 index 0744ac89a..000000000 --- a/jjb/3rd_party_ci/create-apex-vms.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -set -o errexit -set -o nounset -set -o pipefail - -# clone opnfv sdnvpn repo -git clone https://gerrit.opnfv.org/gerrit/p/sdnvpn.git $WORKSPACE/sdnvpn - -. $WORKSPACE/sdnvpn/odl-pipeline/odl-pipeline-common.sh -pushd $LIB -./test_environment.sh --env-number $APEX_ENV_NUMBER --cloner-info $CLONER_INFO --snapshot-disks $SNAPSHOT_DISKS --vjump-hosts $VIRTUAL_JUMPHOSTS -popd diff --git a/jjb/3rd_party_ci/detect-snapshot.sh b/jjb/3rd_party_ci/detect-snapshot.sh deleted file mode 100755 index 77788aa2c..000000000 --- a/jjb/3rd_party_ci/detect-snapshot.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash -set -o errexit -set -o nounset -set -o pipefail - -echo "Detecting requested OpenStack branch and topology type in gerrit comment" -parsed_comment=$(echo $GERRIT_EVENT_COMMENT_TEXT | sed -n 's/^.*check-opnfv\s*//p') -parsed_comment=$(echo $parsed_comment | sed -n 's/\s*$//p') -if [ ! -z "$parsed_comment" ]; then - if echo $parsed_comment | grep -E '^[a-z]+-(no)?ha'; then - os_version=${parsed_comment%%"-"*} - topo=${parsed_comment#*"-"} - echo "OS version detected in gerrit comment: ${os_version}" - echo "Topology type detected in gerrit comment: ${topo}" - else - echo "Invalid format given for scenario in gerrit comment: ${parsed_comment}...aborting" - exit 1 - fi -else - echo "No scenario given in gerrit comment, will use default (master OpenStack, noha)" - os_version='master' - topo='noha' -fi - -echo "Writing variables to file" -cat > detected_snapshot << EOI -OS_VERSION=$os_version -TOPOLOGY=$topo -SNAP_CACHE=$HOME/snap_cache/$os_version/$topo -EOI diff --git a/jjb/3rd_party_ci/download-netvirt-artifact.sh b/jjb/3rd_party_ci/download-netvirt-artifact.sh deleted file mode 100755 index ac7f76ccd..000000000 --- a/jjb/3rd_party_ci/download-netvirt-artifact.sh +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/bash -set -o errexit -set -o nounset -set -o pipefail - -echo "Attempting to fetch the artifact location from ODL Jenkins" -if [ "$ODL_BRANCH" != 'master' ]; then - DIST=$(echo ${ODL_BRANCH} | sed -rn 's#([a-zA-Z]+)/([a-zA-Z]+)#\2#p') - ODL_BRANCH=$(echo ${ODL_BRANCH} | sed -rn 's#([a-zA-Z]+)/([a-zA-Z]+)#\1%2F\2#p') -else - DIST='neon' -fi - -echo "ODL Distribution is ${DIST}" -ODL_ZIP="karaf-SNAPSHOT.zip" -CHANGE_DETAILS_URL="https://git.opendaylight.org/gerrit/changes/${GERRIT_PROJECT}~${ODL_BRANCH}~${GERRIT_CHANGE_ID}/detail" -# due to limitation with the Jenkins Gerrit Trigger, we need to use Gerrit REST API to get the change details -ODL_BUILD_JOB_NUM=$(curl --fail ${CHANGE_DETAILS_URL} | grep -Eo "${GERRIT_PROJECT}-distribution-check-${DIST}/[0-9]+" | tail -1 | grep -Eo [0-9]+) -DISTRO_CHECK_CONSOLE_LOG="https://logs.opendaylight.org/releng/vex-yul-odl-jenkins-1/${GERRIT_PROJECT}-distribution-check-${DIST}/${ODL_BUILD_JOB_NUM}/console.log.gz" -NETVIRT_ARTIFACT_URL=$(curl --fail --compressed ${DISTRO_CHECK_CONSOLE_LOG} | grep 'BUNDLE_URL' | cut -d = -f 2) - -echo -e "URL to artifact is\n\t$NETVIRT_ARTIFACT_URL" - -echo "Downloading the artifact. This could take time..." -if ! wget -q -O $ODL_ZIP $NETVIRT_ARTIFACT_URL; then - echo "The artifact does not exist! Probably removed due to ODL Jenkins artifact retention policy." - echo "Use 'recheck' on the gerrit to get artifact rebuilt." - exit 1 -fi - -#TODO(trozet) remove this once odl-pipeline accepts zip files -echo "Converting artifact zip to tar.gz" -UNZIPPED_DIR=`dirname $(unzip -qql ${ODL_ZIP} | head -n1 | tr -s ' ' | cut -d' ' -f5-)` -unzip ${ODL_ZIP} -tar czf /tmp/${NETVIRT_ARTIFACT} ${UNZIPPED_DIR} - -echo "Download complete" -ls -al /tmp/${NETVIRT_ARTIFACT} diff --git a/jjb/3rd_party_ci/install-netvirt.sh b/jjb/3rd_party_ci/install-netvirt.sh deleted file mode 100755 index 232d60e5c..000000000 --- a/jjb/3rd_party_ci/install-netvirt.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/bash -set -o errexit -set -o nounset -set -o pipefail - -SNAP_CACHE=$HOME/snap_cache/$OS_VERSION/$TOPOLOGY -# clone opnfv sdnvpn repo -git clone https://gerrit.opnfv.org/gerrit/p/sdnvpn.git $WORKSPACE/sdnvpn - -if [ ! -f "/tmp/${NETVIRT_ARTIFACT}" ]; then - echo "ERROR: /tmp/${NETVIRT_ARTIFACT} specified as NetVirt Artifact, but file does not exist" - exit 1 -fi - -if [ ! -f "${SNAP_CACHE}/node.yaml" ]; then - echo "ERROR: node.yaml pod config missing in ${SNAP_CACHE}" - exit 1 -fi - -if [ ! -f "${SNAP_CACHE}/id_rsa" ]; then - echo "ERROR: id_rsa ssh creds missing in ${SNAP_CACHE}" - exit 1 -fi - -# TODO (trozet) snapshot should have already been unpacked into cache folder -# but we really should check the cache here, and not use a single cache folder -# for when we support multiple jobs on a single slave -pushd sdnvpn/odl-pipeline/lib > /dev/null -git fetch https://gerrit.opnfv.org/gerrit/sdnvpn refs/changes/17/59017/5 && git checkout FETCH_HEAD -./odl_reinstaller.sh --pod-config ${SNAP_CACHE}/node.yaml \ - --odl-artifact /tmp/${NETVIRT_ARTIFACT} --ssh-key-file ${SNAP_CACHE}/id_rsa -popd > /dev/null diff --git a/jjb/3rd_party_ci/odl-netvirt.yaml b/jjb/3rd_party_ci/odl-netvirt.yaml deleted file mode 100644 index 15d28486f..000000000 --- a/jjb/3rd_party_ci/odl-netvirt.yaml +++ /dev/null @@ -1,287 +0,0 @@ ---- -- project: - name: 'netvirt' - - project: 'netvirt' - - installer: 'netvirt' - ##################################### - # branch definitions - ##################################### - stream: - - master: - branch: '{stream}' - gs-pathname: '' - disabled: false - - oxygen: - branch: 'stable/oxygen' - gs-pathname: '' - disabled: false - ##################################### - # patch verification phases - ##################################### - phase: - - 'create-apex-vms': - slave-label: 'apex-virtual-master' - - 'install-netvirt': - slave-label: 'apex-virtual-master' - - 'postprocess': - slave-label: 'apex-virtual-master' - ##################################### - # jobs - ##################################### - jobs: - - 'odl-netvirt-verify-virtual-{stream}' - - 'odl-netvirt-verify-virtual-{phase}-{stream}' - -##################################### -# job templates -##################################### -- job-template: - name: 'odl-netvirt-verify-virtual-{stream}' - - project-type: multijob - - disabled: '{obj:disabled}' - - concurrent: true - - properties: - - logrotate-default - - throttle: - enabled: true - max-total: 5 - max-per-node: 1 - option: 'project' - - build-blocker: - use-build-blocker: true - blocking-jobs: - - 'apex-verify.*' - - 'apex-.*-promote.*' - - 'apex-virtual.*' - - 'odl-netvirt-verify-virtual-create-apex-vms-.*' - - 'odl-netvirt-verify-virtual-install-netvirt-.*' - - 'functest-netvirt-virtual-suite-.*' - - 'odl-netvirt-verify-virtual-postprocess-.*' - blocking-level: 'NODE' - scm: - - git: - url: https://gerrit.opnfv.org/gerrit/apex - branches: - - 'origin/master' - timeout: 15 - wipe-workspace: true - - parameters: - - project-parameter: - project: '{project}' - branch: '{branch}' - - string: - name: NETVIRT_ARTIFACT - default: distribution-karaf.tar.gz - - 'apex-virtual-master-defaults' - - triggers: - - gerrit: - server-name: 'git.opendaylight.org' - trigger-on: - # yamllint disable rule:line-length - # - comment-added-contains-event: - # comment-contains-value: 'https://jenkins.opendaylight.org/releng/job/netvirt-patch-test-current-carbon/.*?/ : SUCCESS' - # - comment-added-contains-event: - # comment-contains-value: 'https://jenkins.opendaylight.org/releng/job/netvirt-patch-test-current-carbon/.*?/ : UNSTABLE' - # yamllint enable rule:line-length - - comment-added-contains-event: - comment-contains-value: 'check-opnfv' - projects: - - project-compare-type: 'ANT' - project-pattern: '*' - branches: - - branch-compare-type: 'ANT' - branch-pattern: '**/{branch}' - readable-message: true - - builders: - - description-setter: - description: "Built on $NODE_NAME" - - detect-opnfv-snapshot - - inject: - properties-file: detected_snapshot - - multijob: - name: create-apex-vms - condition: SUCCESSFUL - projects: - - name: 'odl-netvirt-verify-virtual-create-apex-vms-{stream}' - current-parameters: false - predefined-parameters: | - BRANCH=$BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - GERRIT_CHANGE_ID=$GERRIT_CHANGE_ID - GERRIT_PATCHSET_NUMBER=$GERRIT_PATCHSET_NUMBER - GERRIT_PATCHSET_REVISION=$GERRIT_PATCHSET_REVISION - NETVIRT_ARTIFACT=$NETVIRT_ARTIFACT - APEX_ENV_NUMBER=$APEX_ENV_NUMBER - GERRIT_EVENT_COMMENT_TEXT=$GERRIT_EVENT_COMMENT_TEXT - TOPOLOGY=$TOPOLOGY - OS_VERSION=$OS_VERSION - node-parameters: true - kill-phase-on: FAILURE - abort-all-job: true - - multijob: - name: install-netvirt - condition: SUCCESSFUL - projects: - - name: 'odl-netvirt-verify-virtual-install-netvirt-{stream}' - current-parameters: false - predefined-parameters: | - ODL_BRANCH=$BRANCH - BRANCH=$BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - GERRIT_CHANGE_ID=$GERRIT_CHANGE_ID - GERRIT_PATCHSET_NUMBER=$GERRIT_PATCHSET_NUMBER - GERRIT_PATCHSET_REVISION=$GERRIT_PATCHSET_REVISION - GERRIT_PROJECT=$GERRIT_PROJECT - NETVIRT_ARTIFACT=$NETVIRT_ARTIFACT - TOPOLOGY=$TOPOLOGY - OS_VERSION=$OS_VERSION - node-parameters: true - kill-phase-on: FAILURE - abort-all-job: true - - multijob: - name: csit - condition: ALWAYS - projects: - - name: cperf-apex-csit-master - predefined-parameters: | - ODL_BRANCH=$BRANCH - RC_FILE_PATH=$SNAP_CACHE/overcloudrc - NODE_FILE_PATH=$SNAP_CACHE/node.yaml - SSH_KEY_PATH=$SNAP_CACHE/id_rsa - ODL_CONTAINERIZED=false - OS_VERSION=$OS_VERSION - node-parameters: true - kill-phase-on: FAILURE - abort-all-job: false - - multijob: - name: csit-collect-logs - condition: ALWAYS - projects: - - name: cperf-upload-logs-csit - predefined-parameters: | - ODL_BRANCH=$BRANCH - OS_VERSION=$OS_VERSION - node-parameters: true - kill-phase-on: FAILURE - abort-all-job: false - - multijob: - name: apex-fetch-logs - condition: ALWAYS - projects: - - name: 'apex-fetch-logs-{stream}' - current-parameters: false - node-parameters: true - kill-phase-on: NEVER - abort-all-job: true - git-revision: false - - multijob: - name: postprocess - condition: ALWAYS - projects: - - name: 'odl-netvirt-verify-virtual-postprocess-{stream}' - current-parameters: false - predefined-parameters: | - BRANCH=$BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - GERRIT_CHANGE_ID=$GERRIT_CHANGE_ID - GERRIT_PATCHSET_NUMBER=$GERRIT_PATCHSET_NUMBER - GERRIT_PATCHSET_REVISION=$GERRIT_PATCHSET_REVISION - NETVIRT_ARTIFACT=$NETVIRT_ARTIFACT - node-parameters: true - kill-phase-on: FAILURE - abort-all-job: false - -- job-template: - name: 'odl-netvirt-verify-virtual-{phase}-{stream}' - - disabled: '{obj:disabled}' - - concurrent: true - - properties: - - logrotate-default - - throttle: - enabled: true - max-total: 5 - max-per-node: 1 - option: 'project' - - build-blocker: - use-build-blocker: true - blocking-jobs: - - 'odl-netvirt-verify-virtual-create-apex-vms-.*' - - 'odl-netvirt-verify-virtual-install-netvirt-.*' - - 'functest-netvirt-virtual-suite-.*' - - 'odl-netvirt-verify-virtual-postprocess-.*' - blocking-level: 'NODE' - - wrappers: - - ssh-agent-wrapper - - timeout: - timeout: 360 - fail: true - - scm: - - git: - url: https://gerrit.opnfv.org/gerrit/apex - branches: - - 'origin/master' - timeout: 15 - wipe-workspace: true - - parameters: - - project-parameter: - project: '{project}' - branch: '{branch}' - - '{slave-label}-defaults' - - '{installer}-defaults' - - string: - name: DEPLOY_SCENARIO - default: 'os-odl-nofeature-noha' - description: 'Scenario to deploy and test' - - string: - name: GS_URL - default: artifacts.opnfv.org/apex - description: "URL to Google Storage with snapshot artifacts." - - builders: - - description-setter: - description: "Built on $NODE_NAME" - - '{project}-verify-{phase}-builder' -##################################### -# builder macros -##################################### -- builder: - name: 'netvirt-verify-create-apex-vms-builder' - builders: - - shell: - !include-raw: ../apex/apex-snapshot-deploy.sh -- builder: - name: 'netvirt-verify-install-netvirt-builder' - builders: - - shell: - !include-raw: ./download-netvirt-artifact.sh - - shell: - !include-raw: ./install-netvirt.sh -- builder: - name: 'netvirt-verify-postprocess-builder' - builders: - - shell: - !include-raw: ./postprocess-netvirt.sh - -- builder: - name: 'detect-opnfv-snapshot' - builders: - - shell: - !include-raw: ./detect-snapshot.sh diff --git a/jjb/3rd_party_ci/postprocess-netvirt.sh b/jjb/3rd_party_ci/postprocess-netvirt.sh deleted file mode 100755 index 796514259..000000000 --- a/jjb/3rd_party_ci/postprocess-netvirt.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash -set -o errexit -set -o nounset -set -o pipefail - -# clone opnfv sdnvpn repo -git clone https://gerrit.opnfv.org/gerrit/p/sdnvpn.git $WORKSPACE/sdnvpn -. $WORKSPACE/sdnvpn/odl-pipeline/odl-pipeline-common.sh -pushd $LIB -./post_process.sh -popd |