echo "Will download RPMs..."
# Must be RPMs/ISO
- export OPNFV_ARTIFACT_VERSION=$(date -u +"%Y-%m-%d")
- echo "Downloading opnfv-${OPNFV_ARTIFACT_VERSION}.properties"
+ echo "Downloading latest properties file"
# get the properties file in order to get info regarding artifacts
- curl --fail -s -o $BUILD_DIRECTORY/opnfv.properties http://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.properties
+ curl --fail -s -o $BUILD_DIRECTORY/opnfv.properties http://$GS_URL/latest.properties
# source the file so we get OPNFV vars
source $BUILD_DIRECTORY/opnfv.properties
set -o pipefail
SSH_OPTIONS=(-o StrictHostKeyChecking=no -o GlobalKnownHostsFile=/dev/null -o UserKnownHostsFile=/dev/null -o LogLevel=error)
-SNAP_TYPE=$(echo ${JOB_NAME} | sed -n 's/^apex-\(.\+\)-promote.*$/\1/p')
+
+if [ -z "$SNAP_TYPE" ]; then
+ echo "ERROR: SNAP_TYPE not provided...exiting"
+ exit 1
+fi
echo "Creating Apex snapshot..."
echo "-------------------------"
uploadsnap () {
# Uploads snapshot artifact and updated properties file
echo "Uploading snapshot artifacts"
- SNAP_TYPE=$(echo ${JOB_NAME} | sed -n 's/^apex-\(.\+\)-promote.*$/\1/p')
+ if [ -z "$SNAP_TYPE" ]; then
+ echo "ERROR: SNAP_TYPE not provided...exiting"
+ exit 1
+ fi
gsutil cp $WORKSPACE/apex-${SNAP_TYPE}-snap-`date +%Y-%m-%d`.tar.gz gs://$GS_URL/ > gsutil.iso.log
if [ "$SNAP_TYPE" == 'csit' ]; then
gsutil cp $WORKSPACE/snapshot.properties gs://$GS_URL/snapshot.properties > gsutil.latest.log
virtual-slave: 'apex-virtual-master'
baremetal-slave: 'apex-baremetal-master'
verify-scenario: 'os-odl-nofeature-ha'
+ concurrent-builds: 3
- danube:
branch: 'stable/danube'
virtual-slave: 'apex-virtual-danube'
baremetal-slave: 'apex-baremetal-danube'
verify-scenario: 'os-odl_l3-nofeature-ha'
+ concurrent-builds: 1
disabled: false
platform:
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-daily.*'
- - 'apex-deploy.*'
- - 'apex-runner.*'
- throttle:
max-per-node: 3
max-total: 10
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-daily.*'
- - 'apex-deploy.*'
- - 'apex-runner.*'
- throttle:
max-per-node: 3
max-total: 10
properties:
- logrotate-default
- throttle:
- max-per-node: 3
+ max-per-node: {concurrent-builds}
max-total: 10
option: 'project'
+ - build-blocker:
+ use-build-blocker: true
+ block-level: 'NODE'
+ blocking-jobs:
+ - 'apex-verify-iso-{stream}'
builders:
- 'apex-build'
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-deploy.*'
- throttle:
max-per-node: 1
max-total: 10
node-parameters: false
current-parameters: false
predefined-parameters: |
- DEPLOY_SCENARIO=os-odl_l2-netvirt_gbp_fdio-noha
+ DEPLOY_SCENARIO=os-odl_netvirt-fdio-noha
OPNFV_CLEAN=yes
kill-phase-on: NEVER
abort-all-job: true
condition: SUCCESSFUL
projects:
- name: 'apex-create-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=csit
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
condition: SUCCESSFUL
projects:
- name: 'apex-upload-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=csit
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
- name: 'apex-deploy-virtual-{stream}'
current-parameters: false
predefined-parameters: |
- DEPLOY_SCENARIO=os-odl_l2-netvirt_gbp_fdio-noha
+ DEPLOY_SCENARIO=os-odl_netvirt-fdio-noha
OPNFV_CLEAN=yes
GERRIT_BRANCH=$GERRIT_BRANCH
GERRIT_REFSPEC=$GERRIT_REFSPEC
condition: SUCCESSFUL
projects:
- name: 'apex-create-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=fdio
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
condition: SUCCESSFUL
projects:
- name: 'apex-upload-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=fdio
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
virtual-slave: 'apex-virtual-master'
baremetal-slave: 'apex-baremetal-master'
verify-scenario: 'os-odl-nofeature-ha'
+ concurrent-builds: 3
- danube:
branch: 'stable/danube'
virtual-slave: 'apex-virtual-danube'
baremetal-slave: 'apex-baremetal-danube'
verify-scenario: 'os-odl_l3-nofeature-ha'
+ concurrent-builds: 1
disabled: false
platform:
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-daily.*'
- - 'apex-deploy.*'
- - 'apex-runner.*'
- throttle:
max-per-node: 3
max-total: 10
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-daily.*'
- - 'apex-deploy.*'
- - 'apex-runner.*'
- throttle:
max-per-node: 3
max-total: 10
properties:
- logrotate-default
- throttle:
- max-per-node: 3
+ max-per-node: {concurrent-builds}
max-total: 10
option: 'project'
+ - build-blocker:
+ use-build-blocker: true
+ block-level: 'NODE'
+ blocking-jobs:
+ - 'apex-verify-iso-{stream}'
builders:
- 'apex-build'
properties:
- logrotate-default
- - build-blocker:
- use-build-blocker: true
- block-level: 'NODE'
- blocking-jobs:
- - 'apex-deploy.*'
- throttle:
max-per-node: 1
max-total: 10
condition: SUCCESSFUL
projects:
- name: 'apex-create-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=csit
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
condition: SUCCESSFUL
projects:
- name: 'apex-upload-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=csit
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
- name: 'apex-deploy-virtual-{stream}'
current-parameters: false
predefined-parameters: |
- DEPLOY_SCENARIO=os-odl_l2-netvirt_gbp_fdio-noha
+ DEPLOY_SCENARIO=os-odl_netvirt-fdio-noha
OPNFV_CLEAN=yes
GERRIT_BRANCH=$GERRIT_BRANCH
GERRIT_REFSPEC=$GERRIT_REFSPEC
condition: SUCCESSFUL
projects:
- name: 'apex-create-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=fdio
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
condition: SUCCESSFUL
projects:
- name: 'apex-upload-snapshot'
- current-parameters: true
+ current-parameters: false
+ predefined-parameters: |
+ SNAP_TYPE=fdio
node-parameters: true
kill-phase-on: FAILURE
abort-all-job: true
- 'os-nosdn-kvm-noha'
- 'os-odl_l2-fdio-noha'
- 'os-odl_l2-fdio-ha'
- - 'os-odl_l2-netvirt_gbp_fdio-noha'
+ - 'os-odl_netvirt-fdio-noha'
- 'os-odl_l2-sfc-noha'
- 'os-odl_l3-nofeature-noha'
- 'os-odl_l3-nofeature-ha'
#set -e
[[ $GERRIT_REFSPEC_DEBUG == true ]] && redirect="/dev/stdout" || redirect="/dev/null"
BOTTLENECKS_IMAGE=opnfv/bottlenecks
+REPORT="True"
if [[ $SUITE_NAME == rubbos || $SUITE_NAME == vstf ]]; then
echo "Bottlenecks: to pull image $BOTTLENECKS_IMAGE:${DOCKER_TAG}"
echo "Bottlenecks: pulling tutum/influxdb for yardstick"
docker pull tutum/influxdb:0.13
sleep 5
- docker exec bottleneckcompose_bottlenecks_1 python ${POSCA_SCRIPT}/run_posca.py testcase $TEST_CASE
+ docker exec bottleneckcompose_bottlenecks_1 python ${POSCA_SCRIPT}/run_posca.py testcase $TEST_CASE $REPORT
elif [[ $SUITE_NAME == posca_stress_ping ]]; then
TEST_CASE=posca_factor_ping
sleep 5
- docker exec bottleneckcompose_bottlenecks_1 python ${POSCA_SCRIPT}/run_posca.py testcase $TEST_CASE
+ docker exec bottleneckcompose_bottlenecks_1 python ${POSCA_SCRIPT}/run_posca.py testcase $TEST_CASE $REPORT
fi
echo "Bottlenecks: cleaning up docker-compose images and dockers"
echo "This is $INSTALLER_TYPE deploy job!"
echo "--------------------------------------------------------"
-DEPLOY_SCENARIO=${DEPLOY_SCENARIO:-"os-nosdn-nofeature-ha"}
+DEPLOY_SCENARIO=${DEPLOY_SCENARIO:-"os-nosdn-nofeature-noha"}
BRIDGE=${BRIDGE:-pxebr}
LAB_NAME=${NODE_NAME/-*}
POD_NAME=${NODE_NAME/*-}
cp -r securedlab/labs .
DEPLOY_COMMAND="sudo ./ci/deploy/deploy.sh -b $BASE_DIR \
- -l $LAB_NAME -p $POD_NAME -B $BRIDGE"
+ -l $LAB_NAME -p $POD_NAME -B $BRIDGE -s $DEPLOY_SCENARIO"
# log info to console
echo """
set -e
[[ $CI_DEBUG == true ]] && redirect="/dev/stdout" || redirect="/dev/null"
-DOVETAIL_HOME=/home/opnfv/cvp
+DOVETAIL_HOME=${WORKSPACE}/cvp
if [ -d ${DOVETAIL_HOME} ]; then
sudo rm -rf ${DOVETAIL_HOME}/*
else
git clone https://gerrit.opnfv.org/gerrit/releng ${releng_repo} >/dev/null
if [[ ${INSTALLER_TYPE} != 'joid' ]]; then
- ${releng_repo}/utils/fetch_os_creds.sh -d ${OPENRC} -i ${INSTALLER_TYPE} -a ${INSTALLER_IP} >${redirect}
+ sudo /bin/bash ${releng_repo}/utils/fetch_os_creds.sh -d ${OPENRC} -i ${INSTALLER_TYPE} -a ${INSTALLER_IP} >${redirect}
fi
if [[ -f $OPENRC ]]; then
echo "INFO: openstack credentials path is $OPENRC"
cat $OPENRC
else
- echo "ERROR: file $OPENRC does not exist."
+ echo "ERROR: cannot find file $OPENRC. Please check if it is existing."
+ sudo ls -al ${DOVETAIL_CONFIG}
exit 1
fi
echo "file ${DOVETAIL_CONFIG}/pod.yaml:"
cat ${DOVETAIL_CONFIG}/pod.yaml
else
- echo "Error: There doesn't exist file ${DOVETAIL_CONFIG}/pod.yaml."
+ echo "Error: cannot find file ${DOVETAIL_CONFIG}/pod.yaml. Please check if it is existing."
+ sudo ls -al ${DOVETAIL_CONFIG}
echo "HA test cases may not run properly."
fi
sshpass -p r00tme sudo scp $ssh_options root@${INSTALLER_IP}:~/.ssh/id_rsa ${DOVETAIL_CONFIG}/id_rsa
fi
+# sdnvpn test case needs to download this image first before running
+sudo wget -nc http://artifacts.opnfv.org/sdnvpn/ubuntu-16.04-server-cloudimg-amd64-disk1.img -P ${DOVETAIL_CONFIG}
+
opts="--privileged=true -id"
docker_volume="-v /var/run/docker.sock:/var/run/docker.sock"
echo "Dovetail: Pulling image opnfv/dovetail:${DOCKER_TAG}"
docker pull opnfv/dovetail:$DOCKER_TAG >$redirect
-cmd="docker run ${opts} -e ${DOVETAIL_HOME} ${docker_volume} ${dovetail_home_volume} \
+cmd="docker run ${opts} -e DOVETAIL_HOME=${DOVETAIL_HOME} ${docker_volume} ${dovetail_home_volume} \
${sshkey} opnfv/dovetail:${DOCKER_TAG} /bin/bash"
echo "Dovetail: running docker run command: ${cmd}"
${cmd} >${redirect}
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
+
+# disable Fuel iso build for master branch
+if [[ "$BRANCH" == 'master' ]]; then
+ touch $WORKSPACE/.noupload
+ echo "--------------------------------------------------------"
+ echo "Done!"
+ exit 0
+fi
+
set -o errexit
set -o nounset
set -o pipefail
- trigger:
name: 'fuel-os-nosdn-nofeature-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 20 * * *'
+ - timed: '' # '5 20 * * *'
- trigger:
name: 'fuel-os-odl_l2-nofeature-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 23 * * *'
+ - timed: '' # '5 23 * * *'
- trigger:
name: 'fuel-os-odl_l3-nofeature-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 2 * * *'
+ - timed: '' # '5 2 * * *'
- trigger:
name: 'fuel-os-nosdn-ovs-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 5 * * *'
+ - timed: '' # '5 5 * * *'
- trigger:
name: 'fuel-os-onos-sfc-ha-baremetal-daily-master-trigger'
triggers:
- trigger:
name: 'fuel-os-odl_l2-sfc-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 11 * * *'
+ - timed: '' # '5 11 * * *'
- trigger:
name: 'fuel-os-odl_l2-bgpvpn-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 14 * * *'
+ - timed: '' # '5 14 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '5 17 * * *'
+ - timed: '' # '5 17 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm_ovs_dpdk-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '30 12 * * *'
+ - timed: '' # '30 12 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm_ovs_dpdk_bar-ha-baremetal-daily-master-trigger'
triggers:
- - timed: '30 8 * * *'
+ - timed: '' # '30 8 * * *'
# NOHA Scenarios
- trigger:
name: 'fuel-os-nosdn-nofeature-noha-baremetal-daily-master-trigger'
- trigger:
name: 'fuel-os-odl_l2-nofeature-noha-virtual-daily-master-trigger'
triggers:
- - timed: '35 15 * * *'
+ - timed: '' # '35 15 * * *'
- trigger:
name: 'fuel-os-odl_l3-nofeature-noha-virtual-daily-master-trigger'
triggers:
- - timed: '5 18 * * *'
+ - timed: '' # '5 18 * * *'
- trigger:
name: 'fuel-os-onos-sfc-noha-virtual-daily-master-trigger'
triggers:
- trigger:
name: 'fuel-os-odl_l2-sfc-noha-virtual-daily-master-trigger'
triggers:
- - timed: '35 1 * * *'
+ - timed: '' # '35 1 * * *'
- trigger:
name: 'fuel-os-odl_l2-bgpvpn-noha-virtual-daily-master-trigger'
triggers:
- - timed: '5 4 * * *'
+ - timed: '' # '5 4 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm-noha-virtual-daily-master-trigger'
triggers:
- - timed: '35 6 * * *'
+ - timed: '' # '35 6 * * *'
- trigger:
name: 'fuel-os-nosdn-ovs-noha-virtual-daily-master-trigger'
triggers:
- - timed: '5 9 * * *'
+ - timed: '' # '5 9 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm_ovs_dpdk-noha-virtual-daily-master-trigger'
triggers:
- - timed: '30 16 * * *'
+ - timed: '' # '30 16 * * *'
- trigger:
name: 'fuel-os-nosdn-kvm_ovs_dpdk_bar-noha-virtual-daily-master-trigger'
triggers:
- - timed: '30 20 * * *'
+ - timed: '' # '30 20 * * *'
#-----------------------------------------------
# Triggers for job running on fuel-virtual against danube branch
#-----------------------------------------------
if [[ "$JOB_NAME" =~ "merge" ]]; then
# set simplest scenario for virtual deploys to run for merges
DEPLOY_SCENARIO="os-nosdn-nofeature-ha"
-else
+elif [[ "$BRANCH" != 'master' ]]; then
# for none-merge deployments
# checkout the commit that was used for building the downloaded artifact
# to make sure the ISO and deployment mechanism uses same versions
let global_ret_val+=$?
done
-exit $global_ret_val
+ret_val_file="${HOME}/opnfv/functest/results/${BRANCH##*/}/return_value"
+echo ${global_ret_val}>${ret_val_file}
+
+exit 0
project:
# projects with jobs for master
+ - 'anteater':
+ <<: *master
+ <<: *other-receivers
- 'bottlenecks':
<<: *master
<<: *other-receivers
branch: '{stream}'
gs-pathname: ''
disabled: false
+ docker-tag: 'latest'
- danube:
branch: 'stable/{stream}'
gs-pathname: '/{stream}'
disabled: false
+ docker-tag: 'stable'
- job-template:
name: 'storperf-verify-{stream}'
project: '{project}'
branch: '{branch}'
- 'intel-pod9-defaults'
+ - string:
+ name: DEPLOY_SCENARIO
+ default: 'os-nosdn-nofeature-noha'
+ - string:
+ name: DOCKER_TAG
+ default: '{docker-tag}'
+ description: 'Tag to pull docker image'
scm:
- git-scm
-paramiko>=2.0.1
+paramiko==2.1.2
mock==1.3.0
requests==2.9.1
export DIB_DEV_USER_PWDLESS_SUDO=yes
export DIB_DEV_USER_PASSWORD=devuser
-# Settings for distro: trusty/ubuntu-minimal, 7/centos7, 42.2/suse
-export DIB_OS_RELEASE=${DIB_OS_RELEASE:-trusty}
+# Settings for distro: xenial/ubuntu-minimal, 7/centos7, 42.2/suse
+export DIB_OS_RELEASE=${DIB_OS_RELEASE:-xenial}
export DIB_OS_ELEMENT=${DIB_OS_ELEMENT:-ubuntu-minimal}
# DIB OS packages
execute sandbox script
- sudo -E ./xci-deploy.sh
+ ./xci-deploy.sh
Issuing above command will start aio sandbox deployment and the sandbox
should be ready between 1,5 and 2 hours depending on the host machine.
+Please remember that the user executing the XCI script will need to
+have an ssh key available, and stored in $HOME/.ssh directory.
+You can generate one by executing
+
+ ssh-keygen -t rsa
+
Advanced Usage
--------------
export OPENSTACK_BIFROST_GIT_URL=https://git.openstack.org/openstack/bifrost
export OPENSTACK_OSA_GIT_URL=https://git.openstack.org/openstack/openstack-ansible
export OPENSTACK_OSA_ETC_PATH=/etc/openstack_deploy
-export CLEAN_DIB_IMAGES=false
export OPNFV_HOST_IP=192.168.122.2
export XCI_FLAVOR_ANSIBLE_FILE_PATH=$OPNFV_RELENG_PATH/prototypes/xci/file/$XCI_FLAVOR
export CI_LOOP=${CI_LOOP:-daily}
export ANSIBLE_VERBOSITY=${ANSIBLE_VERBOSITY-""}
export LOG_PATH=${LOG_PATH:-${XCI_DEVEL_ROOT}/opnfv/logs}
export RUN_TEMPEST=${RUN_TEMPEST:-false}
+# Set this to to true to force XCI to re-create the target OS images
+export CLEAN_DIB_IMAGES=${CLEAN_DIB_IMAGES:-false}
PIP=$(which pip)
-sudo -H -E ${PIP} install "pip>6.0"
+${PIP} install --user "pip>6.0"
-pip install ansible==$XCI_ANSIBLE_PIP_VERSION
+${PIP} install --user --upgrade ansible==$XCI_ANSIBLE_PIP_VERSION
from setuptools import setup
setup(
- name="opnfv",
+ name="releng",
version="master",
url="https://www.opnfv.org",
)