summaryrefslogtreecommitdiffstats
path: root/jjb
diff options
context:
space:
mode:
Diffstat (limited to 'jjb')
-rw-r--r--jjb/barometer/barometer-upload-artifact.sh6
-rw-r--r--jjb/compass4nfv/compass-ci-jobs.yml8
-rw-r--r--jjb/doctor/doctor.yml14
-rw-r--r--jjb/dovetail/dovetail-ci-jobs.yml2
-rw-r--r--jjb/functest/functest-daily-jobs.yml8
-rwxr-xr-xjjb/functest/functest-loop.sh6
-rwxr-xr-xjjb/functest/functest-suite.sh6
-rwxr-xr-xjjb/functest/set-functest-env.sh7
-rw-r--r--jjb/global/slave-params.yml24
-rw-r--r--jjb/releng/automate.yml (renamed from jjb/releng/testapi-automate.yml)92
-rw-r--r--jjb/releng/docker-deploy.sh (renamed from jjb/releng/testapi-docker-deploy.sh)26
-rw-r--r--jjb/releng/docker-update.sh34
-rw-r--r--jjb/releng/testapi-docker-update.sh18
13 files changed, 152 insertions, 99 deletions
diff --git a/jjb/barometer/barometer-upload-artifact.sh b/jjb/barometer/barometer-upload-artifact.sh
index 887c4924e..817cc5770 100644
--- a/jjb/barometer/barometer-upload-artifact.sh
+++ b/jjb/barometer/barometer-upload-artifact.sh
@@ -17,12 +17,12 @@ echo "Uploading the barometer RPMs to artifacts.opnfv.org"
echo "---------------------------------------------------"
echo
-gsutil -m cp -r $RPM_DIR/* $OPNFV_ARTIFACT_URL > $WORKSPACE/gsutil.log 2>&1
+gsutil -m cp -r $RPM_DIR/* gs://$OPNFV_ARTIFACT_URL > $WORKSPACE/gsutil.log 2>&1
# Check if the RPMs were pushed
-gsutil ls $OPNFV_ARTIFACT_URL > /dev/null 2>&1
+gsutil ls gs://$OPNFV_ARTIFACT_URL > /dev/null 2>&1
if [[ $? -ne 0 ]]; then
- echo "Problem while uploading barometer RPMs to $OPNFV_ARTIFACT_URL!"
+ echo "Problem while uploading barometer RPMs to gs://$OPNFV_ARTIFACT_URL!"
echo "Check log $WORKSPACE/gsutil.log on the appropriate build server"
exit 1
fi
diff --git a/jjb/compass4nfv/compass-ci-jobs.yml b/jjb/compass4nfv/compass-ci-jobs.yml
index 24724912a..f8c8a31a4 100644
--- a/jjb/compass4nfv/compass-ci-jobs.yml
+++ b/jjb/compass4nfv/compass-ci-jobs.yml
@@ -182,6 +182,7 @@
WED: true
FRI: true
SUN: true
+ use-build-time: true
steps:
- trigger-builds:
- project: 'dovetail-compass-{pod}-proposed_tests-master'
@@ -206,9 +207,10 @@
- condition-kind: day-of-week
day-selector: select-days
days:
- TUE: true
- THU: true
+ TUES: true
+ THURS: true
SAT: true
+ use-build-time: true
steps:
- trigger-builds:
- project: 'dovetail-compass-{pod}-proposed_tests-danube'
@@ -225,7 +227,7 @@
condition-kind: and
condition-operands:
- condition-kind: regex-match
- regex: os-(nosdn|odl_l2)-(nofeature|bgpvpn)-ha
+ regex: os-(nosdn|odl_l2|onos|odl_l3)-nofeature-ha
label: '{scenario}'
- condition-kind: regex-match
regex: master
diff --git a/jjb/doctor/doctor.yml b/jjb/doctor/doctor.yml
index eb230b59d..c5454c799 100644
--- a/jjb/doctor/doctor.yml
+++ b/jjb/doctor/doctor.yml
@@ -17,11 +17,9 @@
installer:
- apex:
- slave-label: 'ool-virtual1'
- pod: 'ool-virtual1'
+ slave-label: 'doctor-apex-verify'
- fuel:
- slave-label: 'ool-virtual2'
- pod: 'ool-virtual2'
+ slave-label: 'doctor-fuel-verify'
#- joid:
# slave-label: 'ool-virtual3'
# pod: 'ool-virtual3'
@@ -34,9 +32,15 @@
- verify:
profiler: 'none'
auto-trigger-name: 'doctor-verify'
+ is-python: false
- profiling:
profiler: 'poc'
auto-trigger-name: 'experimental'
+ is-python: false
+ - python-verify:
+ profiler: 'none'
+ auto-trigger-name: 'doctor-verify'
+ is-python: true
pod:
- arm-pod2:
@@ -148,7 +152,7 @@
default: 'doctor-notification'
- string:
name: TESTCASE_OPTIONS
- default: '-e INSPECTOR_TYPE={inspector} -e PROFILER_TYPE={profiler} -v $WORKSPACE:/home/opnfv/repos/doctor'
+ default: '-e INSPECTOR_TYPE={inspector} -e PROFILER_TYPE={profiler} -e PYTHON_ENABLE={is-python} -v $WORKSPACE:/home/opnfv/repos/doctor'
description: 'Addtional parameters specific to test case(s)'
# functest-parameter
- string:
diff --git a/jjb/dovetail/dovetail-ci-jobs.yml b/jjb/dovetail/dovetail-ci-jobs.yml
index 6bcaea26f..43978f6dc 100644
--- a/jjb/dovetail/dovetail-ci-jobs.yml
+++ b/jjb/dovetail/dovetail-ci-jobs.yml
@@ -25,7 +25,7 @@
branch: 'stable/{stream}'
dovetail-branch: master
gs-pathname: '/{stream}'
- docker-tag: 'cvp.0.1.0'
+ docker-tag: 'cvp.0.2.0'
#-----------------------------------
# POD, PLATFORM, AND BRANCH MAPPING
diff --git a/jjb/functest/functest-daily-jobs.yml b/jjb/functest/functest-daily-jobs.yml
index 8de092d29..fdef6f483 100644
--- a/jjb/functest/functest-daily-jobs.yml
+++ b/jjb/functest/functest-daily-jobs.yml
@@ -203,10 +203,10 @@
installer: fuel
<<: *danube
# PODs for verify jobs triggered by each patch upload
- - ool-virtual1:
- slave-label: '{pod}'
- installer: apex
- <<: *master
+# - ool-virtual1:
+# slave-label: '{pod}'
+# installer: apex
+# <<: *master
#--------------------------------
testsuite:
diff --git a/jjb/functest/functest-loop.sh b/jjb/functest/functest-loop.sh
index a590d9f95..00a5f135b 100755
--- a/jjb/functest/functest-loop.sh
+++ b/jjb/functest/functest-loop.sh
@@ -2,7 +2,11 @@
set +e
[[ "$PUSH_RESULTS_TO_DB" == "true" ]] && flags+="-r"
-cmd="run_tests -t all ${flags}"
+if [ "$BRANCH" == 'master' ]; then
+ cmd="run_tests -t all ${flags}"
+else
+ cmd="python ${FUNCTEST_REPO_DIR}/functest/ci/run_tests.py -t all ${flags}"
+fi
container_id=$(docker ps -a | grep opnfv/functest | awk '{print $1}' | head -1)
docker exec $container_id $cmd
diff --git a/jjb/functest/functest-suite.sh b/jjb/functest/functest-suite.sh
index 469a57726..9b7f1356c 100755
--- a/jjb/functest/functest-suite.sh
+++ b/jjb/functest/functest-suite.sh
@@ -10,7 +10,11 @@ global_ret_val=0
tests=($(echo $FUNCTEST_SUITE_NAME | tr "," "\n"))
for test in ${tests[@]}; do
- cmd="run_tests -t $test"
+ if [ "$BRANCH" == 'master' ]; then
+ cmd="run_tests -t $test"
+ else
+ cmd="python /home/opnfv/repos/functest/functest/ci/run_tests.py -t $test"
+ fi
docker exec $container_id $cmd
let global_ret_val+=$?
done
diff --git a/jjb/functest/set-functest-env.sh b/jjb/functest/set-functest-env.sh
index 01cab5e0f..5f936f5d9 100755
--- a/jjb/functest/set-functest-env.sh
+++ b/jjb/functest/set-functest-env.sh
@@ -90,7 +90,12 @@ if [ $(docker ps | grep "${FUNCTEST_IMAGE}:${DOCKER_TAG}" | wc -l) == 0 ]; then
exit 1
fi
-cmd="prepare_env start"
+if [ "$BRANCH" == 'master' ]; then
+ cmd="prepare_env start"
+else
+ cmd="python ${FUNCTEST_REPO_DIR}/functest/ci/prepare_env.py start"
+fi
+
echo "Executing command inside the docker: ${cmd}"
docker exec ${container_id} ${cmd}
diff --git a/jjb/global/slave-params.yml b/jjb/global/slave-params.yml
index 57442225c..59c5856ca 100644
--- a/jjb/global/slave-params.yml
+++ b/jjb/global/slave-params.yml
@@ -862,15 +862,13 @@
default: https://gerrit.opnfv.org/gerrit/$PROJECT
description: 'Git URL to use on this Jenkins Slave'
- parameter:
- name: 'ool-defaults'
+ name: 'doctor-defaults'
parameters:
- node:
name: SLAVE_NAME
description: 'Slave name on Jenkins'
allowed-slaves:
- - ool-virtual1
- - ool-virtual2
- - ool-virtual3
+ - '{default-slave}'
default-slaves:
- '{default-slave}'
- string:
@@ -882,20 +880,20 @@
default: /root/.ssh/id_rsa
description: 'SSH key to be used'
- parameter:
- name: 'ool-virtual1-defaults'
+ name: 'doctor-apex-verify-defaults'
parameters:
- - 'ool-defaults':
- default-slave: 'ool-virtual1'
+ - 'doctor-defaults':
+ default-slave: 'doctor-apex-verify'
- parameter:
- name: 'ool-virtual2-defaults'
+ name: 'doctor-fuel-verify-defaults'
parameters:
- - 'ool-defaults':
- default-slave: 'ool-virtual2'
+ - 'doctor-defaults':
+ default-slave: 'doctor-fuel-verify'
- parameter:
- name: 'ool-virtual3-defaults'
+ name: 'doctor-joid-verify-defaults'
parameters:
- - 'ool-defaults':
- default-slave: 'ool-virtual3'
+ - 'doctor-defaults':
+ default-slave: 'doctor-joid-verify'
- parameter:
name: 'multisite-virtual-defaults'
parameters:
diff --git a/jjb/releng/testapi-automate.yml b/jjb/releng/automate.yml
index dd76538a3..9eb281de3 100644
--- a/jjb/releng/testapi-automate.yml
+++ b/jjb/releng/automate.yml
@@ -1,20 +1,22 @@
- project:
- name: testapi-automate
+ name: utils-automate
stream:
- master:
branch: '{stream}'
- gs-pathname: ''
+
+ module:
+ - 'testapi'
+ - 'reporting'
phase:
- - 'docker-update'
- 'docker-deploy':
slave-label: 'testresults'
- 'generate-doc'
jobs:
- - 'testapi-automate-{stream}'
- - 'testapi-automate-{phase}-{stream}'
- - 'testapi-verify-{stream}'
+ - '{module}-automate-{stream}'
+ - '{module}-automate-{phase}-{stream}'
+ - '{module}-verify-{stream}'
project: 'releng'
@@ -44,7 +46,7 @@
- mongodb-backup
- job-template:
- name: 'testapi-verify-{stream}'
+ name: '{module}-verify-{stream}'
parameters:
- project-parameter:
@@ -76,10 +78,11 @@
branch-pattern: '**/{branch}'
file-paths:
- compare-type: 'ANT'
- pattern: 'utils/test/testapi/**'
+ pattern: 'utils/test/{module}/**'
builders:
- - run-unit-tests
+ - shell: |
+ bash ./utils/test/{module}/run_test.sh
publishers:
- junit:
@@ -101,7 +104,7 @@
failing: 30
- job-template:
- name: 'testapi-automate-{stream}'
+ name: '{module}-automate-{stream}'
project-type: multijob
@@ -118,8 +121,12 @@
branch: '{branch}'
- string:
name: DOCKER_TAG
- default: "latest"
- description: "Tag name for testapi docker image"
+ default: 'latest'
+ description: 'Tag name for {module} docker image'
+ - string:
+ name: MODULE_NAME
+ default: '{module}'
+ description: "Name of the module"
- 'opnfv-build-defaults'
scm:
@@ -146,24 +153,17 @@
branch-pattern: '**/{branch}'
file-paths:
- compare-type: 'ANT'
- pattern: 'utils/test/testapi/**'
+ pattern: 'utils/test/{module}/**'
builders:
- description-setter:
description: "Built on $NODE_NAME"
- - multijob:
- name: docker-update
- condition: SUCCESSFUL
- projects:
- - name: 'testapi-automate-docker-update-{stream}'
- current-parameters: true
- kill-phase-on: FAILURE
- abort-all-job: true
+ - docker-update
- multijob:
name: docker-deploy
condition: SUCCESSFUL
projects:
- - name: 'testapi-automate-docker-deploy-{stream}'
+ - name: '{module}-automate-docker-deploy-{stream}'
current-parameters: false
predefined-parameters: |
GIT_BASE=$GIT_BASE
@@ -175,7 +175,7 @@
name: generate-doc
condition: SUCCESSFUL
projects:
- - name: 'testapi-automate-generate-doc-{stream}'
+ - name: '{module}-automate-generate-doc-{stream}'
current-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
@@ -184,7 +184,7 @@
- 'email-publisher'
- job-template:
- name: 'testapi-automate-{phase}-{stream}'
+ name: '{module}-automate-{phase}-{stream}'
properties:
- throttle:
@@ -196,10 +196,6 @@
- project-parameter:
project: '{project}'
branch: '{branch}'
- - string:
- name: DOCKER_TAG
- default: "latest"
- description: "Tag name for testapi docker image"
wrappers:
- ssh-agent-wrapper
@@ -213,28 +209,16 @@
builders:
- description-setter:
description: "Built on $NODE_NAME"
- - 'testapi-automate-{phase}-macro'
+ - '{module}-automate-{phase}-macro'
################################
# job builders
################################
- builder:
- name: mongodb-backup
- builders:
- - shell: |
- bash ./jjb/releng/testapi-backup-mongodb.sh
-
-- builder:
- name: 'run-unit-tests'
+ name: 'docker-update'
builders:
- - shell: |
- bash ./utils/test/testapi/run_test.sh
-
-- builder:
- name: 'testapi-automate-docker-update-macro'
- builders:
- - shell: |
- bash ./jjb/releng/testapi-docker-update.sh
+ - shell:
+ !include-raw: ./docker-update.sh
- builder:
name: 'testapi-automate-generate-doc-macro'
@@ -255,10 +239,26 @@
bash ./utils/test/testapi/htmlize/push-doc-artifact.sh
- builder:
+ name: 'reporting-automate-generate-doc-macro'
+ builders:
+ - shell: echo "To Be Done"
+
+- builder:
name: 'testapi-automate-docker-deploy-macro'
builders:
- shell: |
- bash ./jjb/releng/testapi-docker-deploy.sh
+ bash ./jjb/releng/docker-deploy.sh 'sudo docker run -dti -p 8082:8000 -e mongodb_url=mongodb://172.17.0.1:27017 -e swagger_url=http://testresults.opnfv.org/test opnfv/testapi' "http://testresults.opnfv.org/test/swagger/APIs"
+- builder:
+ name: 'reporting-automate-docker-deploy-macro'
+ builders:
+ - shell: |
+ bash ./jjb/releng/docker-deploy.sh 'sudo docker run -itd -p 8084:8000 -e SERVER_URL=http://testresults.opnfv.org/reporting2:8084 opnfv/reporting' "http://testresults.opnfv.org/reporting2/reporting/index.html"
+
+- builder:
+ name: mongodb-backup
+ builders:
+ - shell: |
+ bash ./jjb/releng/testapi-backup-mongodb.sh
################################
# job publishers
@@ -268,6 +268,6 @@
name: 'email-publisher'
publishers:
- email:
- recipients: rohitsakala@gmail.com feng.xiaowei@zte.com.cn
+ recipients: rohitsakala@gmail.com feng.xiaowei@zte.com.cn morgan.richomme@orange.com
notify-every-unstable-build: false
send-to-individuals: true
diff --git a/jjb/releng/testapi-docker-deploy.sh b/jjb/releng/docker-deploy.sh
index 02c5e3a27..b3b930fc4 100644
--- a/jjb/releng/testapi-docker-deploy.sh
+++ b/jjb/releng/docker-deploy.sh
@@ -1,10 +1,30 @@
#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one *
+# or more contributor license agreements. See the NOTICE file *
+# distributed with this work for additional information *
+# regarding copyright ownership. The ASF licenses this file *
+# to you under the Apache License, Version 2.0 (the *
+# "License"); you may not use this file except in compliance *
+# with the License. You may obtain a copy of the License at *
+# *
+# http://www.apache.org/licenses/LICENSE-2.0 *
+# *
+# Unless required by applicable law or agreed to in writing, *
+# software distributed under the License is distributed on an *
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+# KIND, either express or implied. See the License for the *
+# specific language governing permissions and limitations *
+# under the License. *
+
+# Assigning Variables
+command=$1
+url=$2
function check() {
# Verify hosted
sleep 5
- cmd=`curl -s --head --request GET http://testresults.opnfv.org/test/swagger/APIs | grep '200 OK' > /dev/null`
+ cmd=`curl -s --head --request GET ${url} | grep '200 OK' > /dev/null`
rc=$?
echo $rc
@@ -63,7 +83,7 @@ else
fi
echo "Running a container with the new image"
-sudo docker run -dti -p "8082:8000" -e "mongodb_url=mongodb://172.17.0.1:27017" -e "swagger_url=http://testresults.opnfv.org/test" opnfv/testapi:latest
+$command:latest
if check; then
echo "TestResults Hosted."
@@ -71,7 +91,7 @@ else
echo "TestResults Hosting Failed"
if [[ $(sudo docker images | grep "opnfv/testapi" | grep "old" | awk '{print $3}') ]]; then
echo "Running old Image"
- sudo docker run -dti -p "8082:8000" -e "mongodb_url=mongodb://172.17.0.1:27017" -e "swagger_url=http://testresults.opnfv.org/test" opnfv/testapi:old
+ $command:old
exit 1
fi
fi
diff --git a/jjb/releng/docker-update.sh b/jjb/releng/docker-update.sh
new file mode 100644
index 000000000..559ac835c
--- /dev/null
+++ b/jjb/releng/docker-update.sh
@@ -0,0 +1,34 @@
+#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one *
+# or more contributor license agreements. See the NOTICE file *
+# distributed with this work for additional information *
+# regarding copyright ownership. The ASF licenses this file *
+# to you under the Apache License, Version 2.0 (the *
+# "License"); you may not use this file except in compliance *
+# with the License. You may obtain a copy of the License at *
+# *
+# http://www.apache.org/licenses/LICENSE-2.0 *
+# *
+# Unless required by applicable law or agreed to in writing, *
+# software distributed under the License is distributed on an *
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY *
+# KIND, either express or implied. See the License for the *
+# specific language governing permissions and limitations *
+# under the License. *
+
+set -o errexit
+set -o nounset
+
+cd $WORKSPACE/utils/test/$MODULE_NAME/docker/
+
+# Remove previous containers
+docker ps -a | grep "opnfv/$MODULE_NAME" | awk '{ print $1 }' | xargs -r docker rm -f
+
+# Remove previous images
+docker images | grep "opnfv/$MODULE_NAME" | awk '{ print $3 }' | xargs -r docker rmi -f
+
+# Start build
+docker build --no-cache -t opnfv/$MODULE_NAME:$DOCKER_TAG .
+
+# Push Image
+docker push opnfv/$MODULE_NAME:$DOCKER_TAG
diff --git a/jjb/releng/testapi-docker-update.sh b/jjb/releng/testapi-docker-update.sh
deleted file mode 100644
index 84f5c3217..000000000
--- a/jjb/releng/testapi-docker-update.sh
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/bin/bash
-
-set -o errexit
-set -o nounset
-
-cd $WORKSPACE/utils/test/testapi/docker/
-
-# Remove previous containers
-docker ps -a | grep "opnfv/testapi" | awk '{ print $1 }' | xargs -r docker rm -f
-
-# Remove previous images
-docker images | grep "opnfv/testapi" | awk '{ print $3 }' | xargs -r docker rmi -f
-
-# Start build
-docker build --no-cache -t opnfv/testapi:$DOCKER_TAG .
-
-# Push Image
-docker push opnfv/testapi:$DOCKER_TAG