-# this is the job configuration for bgs
- project:
name: compass
installer: 'compass'
jobs:
- - 'compass-verify'
- - 'compass-merge'
+ - 'compass-verify-{stream}'
- 'compass-daily-{stream}'
- - 'compass-build-iso'
- - 'compass-build-ppa'
- - 'compass-deploy-virtual-{flavor}'
- - 'compass-deploy-bare-huawei-us'
+ - 'compass-build-iso-{stream}'
+ - 'compass-build-ppa-{stream}'
+ - 'compass-deploy-virtual-{flavor}-{stream}'
+ - 'compass-deploy-bare-huawei-us-{stream}'
- # stream: branch with - in place of / (eg. stable-helium)
- # branch: branch (eg. stable/helium)
+# only master branch is enabled at the moment to keep no of jobs sane
stream:
- master:
- branch: 'master'
+ branch: '{stream}'
+ gs-pathname: ''
+# - brahmaputra:
+# branch: 'stable/{stream}'
+# gs-pathname: '/{stream}'
flavor:
- cluster-odl:
# job templates
########################
- job-template:
- name: 'compass-verify'
-
- project-type: freestyle
+ name: 'compass-verify-{stream}'
disabled: false
max-total: 3
max-per-node: 1
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
-
parameters:
- project-parameter:
project: '{project}'
- gerrit-parameter:
- branch: 'master'
+ branch: '{branch}'
- compass-parameter:
installer: '{installer}'
+ gs-pathname: '{gs-pathname}'
- string:
name: FLAVOR_CONF
default: 'virtual_cluster'
refspec: '$GERRIT_REFSPEC'
choosing-strategy: 'gerrit'
- wrappers:
- - ssh-agent-credentials:
- user: '{ssh-credentials}'
-
triggers:
- gerrit:
trigger-on:
project-pattern: '{project}'
branches:
- branch-compare-type: 'ANT'
- branch-pattern: '**/master'
+ branch-pattern: '**/{branch}'
forbidden-file-paths:
- compare-type: ANT
- pattern: 'docs/**'
+ pattern: 'docs/**|.gitignore'
builders:
- 'builder-compass-build-iso'
allow-empty: 'true'
fingerprint: true
-- job-template:
- name: 'compass-merge'
-
- # builder-merge job to run JJB update
- #
- # This job's purpose is to update all the JJB
-
- project-type: freestyle
-
- node: huawei-build
-
- concurrent: true
-
- properties:
- - throttle:
- enabled: true
- max-total: 3
- max-per-node: 1
-
- logrotate:
- daysToKeep: 30
- numToKeep: 40
- artifactDaysToKeep: -1
- artifactNumToKeep: 5
-
- parameters:
- - project-parameter:
- project: '{project}'
- - gerrit-parameter:
- branch: 'master'
- - compass-parameter:
- installer: '{installer}'
-
- scm:
- - gerrit-trigger-scm:
- credentials-id: '{ssh-credentials}'
- refspec: ''
- choosing-strategy: 'default'
-
- wrappers:
- - ssh-agent-credentials:
- user: '{ssh-credentials}'
-
- triggers:
- - gerrit:
- trigger-on:
- - change-merged-event
- - comment-added-contains-event:
- comment-contains-value: 'remerge'
- projects:
- - project-compare-type: 'ANT'
- project-pattern: '{project}'
- branches:
- - branch-compare-type: 'ANT'
- branch-pattern: '**/master'
-
- builders:
- - 'builder-compass-merge'
-
- job-template:
name: 'compass-daily-{stream}'
- project-type: freestyle
-
node: huawei-build
concurrent: true
project: '{project}'
- compass-parameter:
installer: '{installer}'
+ gs-pathname: '{gs-pathname}'
scm:
- git-scm:
branch: '{branch}'
triggers:
- - timed: '@midnight'
-
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
+ - timed: 'H 16 * * *'
builders:
- trigger-builds:
- - project: 'compass-build-iso'
+ - project: 'compass-build-iso-{stream}'
git-revision: true
block: true
- trigger-builds:
- - project: 'compass-deploy-virtual-cluster'
+ - project: 'compass-deploy-virtual-cluster-{stream}'
git-revision: true
block: true
-# - trigger-builds:
-# - project: 'compass-deploy-virtual-cluster-odl'
-# git-revision: true
-# block: true
- trigger-builds:
- - project: 'compass-deploy-virtual-cluster-onos'
+ - project: 'compass-deploy-virtual-cluster-odl-{stream}'
+ git-revision: true
+ block: true
+ - trigger-builds:
+ - project: 'compass-deploy-virtual-cluster-onos-{stream}'
+ git-revision: true
+ block: true
+ - trigger-builds:
+ - project: 'compass-deploy-bare-huawei-us-{stream}'
git-revision: true
block: true
-- job-template:
- name: 'compass-build-iso'
- project-type: freestyle
+- job-template:
+ name: 'compass-build-iso-{stream}'
node: ericsson-build
max-total: 1
max-per-node: 1
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
-
parameters:
- project-parameter:
project: '{project}'
- compass-parameter:
installer: '{installer}'
+ gs-pathname: '{gs-pathname}'
scm:
- git-scm:
credentials-id: '{ssh-credentials}'
refspec: ''
- branch: 'master'
+ branch: '{branch}'
builders:
- 'builder-compass-build-iso'
- 'builder-compass-workspace-cleanup'
- job-template:
- name: 'compass-build-ppa'
+ name: 'compass-build-ppa-{stream}'
description: "build ppa(using docker) in huawei lab"
- project-type: freestyle
-
node: huawei-build
concurrent: true
max-total: 1
max-per-node: 1
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
-
parameters:
- project-parameter:
project: '{project}'
- compass-parameter:
installer: '{installer}'
+ gs-pathname: '{gs-pathname}'
scm:
- git-scm:
credentials-id: '{ssh-credentials}'
refspec: ''
- branch: 'master'
+ branch: '{branch}'
triggers:
- timed: 'H 16 * * *'
- 'builder-compass-make-ppa'
- job-template:
- name: 'compass-deploy-virtual-{flavor}'
-
- project-type: freestyle
+ name: 'compass-deploy-virtual-{flavor}-{stream}'
disabled: false
project: '{project}'
- compass-parameter:
installer: '{installer}'
+ gs-pathname: '{gs-pathname}'
- string:
name: FLAVOR_CONF
default: '{conf}'
description: ""
-
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
-
-
builders:
- 'builder-compass-ci-preclean-workspace'
- 'builder-compass-download-artifact'
allow-empty: 'true'
fingerprint: true
-
- job-template:
- name: 'compass-deploy-bare-huawei-us'
-
- project-type: freestyle
+ name: 'compass-deploy-bare-huawei-us-{stream}'
disabled: false
project: '{project}'
- compass-parameter:
installer: '{installer}'
-
- logrotate:
- daysToKeep: 30
- numToKeep: 10
- artifactDaysToKeep: -1
- artifactNumToKeep: -1
+ gs-pathname: '{gs-pathname}'
builders:
- 'builder-compass-ci-preclean-workspace'
allow-empty: 'true'
fingerprint: true
-
########################
# parameter macros
########################
description: "Used for overriding the GIT URL coming from Global Jenkins configuration in case if the stuff is done on none-LF HW."
- string:
name: GS_URL
- default: artifacts.opnfv.org/$PROJECT/
+ default: artifacts.opnfv.org/$PROJECT{gs-pathname}
description: "URL to Google Storage."
- string:
name: GS_URL_PROXY
- string:
name: PPA_CACHE
default: "$WORKSPACE/work/repo/"
+ - choice:
+ name: COMPASS_OPENSTACK_VERSION
+ choices:
+ - 'liberty'
+ - 'juno'
+ - choice:
+ name: COMPASS_OS_VERSION
+ choices:
+ - 'trusty'
+ - 'centos7'
########################
# builder macros
########################
-- builder:
- name: 'builder-compass-merge'
- builders:
- - shell: |
- #!/bin/bash
- echo "Hello World!"
-
- builder:
name: 'builder-compass-make-ppa'
builders:
echo
export ISO_URL=file://$BUILD_DIRECTORY/compass.iso
+ sudo brctl addbr vnic_ci
+ sudo ifconfig vnic_ci up
+ export EXTERNAL_NIC=vnic_ci
cd $WORKSPACE
+ export OS_VERSION=${COMPASS_OS_VERSION}
+ export OPENSTACK_VERSION=${COMPASS_OPENSTACK_VERSION}
./deploy.sh $FLAVOR_CONF
if [ $? -ne 0 ]; then
echo "depolyment failed!"
echo "Done!"
ssh_options="-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
- sshpass -p root scp 2>/dev/null $ssh_options root@${installer_ip}:/var/ansible/run/openstack_juno-opnfv2/ansible.log ./ &> /dev/null
+ sshpass -p root scp 2>/dev/null $ssh_options root@${installer_ip}:/var/ansible/run/openstack_${COMPASS_OPENSTACK_VERSION}-opnfv2/ansible.log ./ &> /dev/null
exit $deploy_ret
cd $WORKSPACE
+ export OS_VERSION=${COMPASS_OS_VERSION}
+ export OPENSTACK_VERSION=${COMPASS_OPENSTACK_VERSION}
./deploy.sh --dha $CONFDIR/dha.yml --network $CONFDIR/network.yml
if [ $? -ne 0 ]; then
echo "depolyment failed!"
echo "Done!"
ssh_options="-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
- sshpass -p root scp 2>/dev/null $ssh_options root@${installer_ip}:/var/ansible/run/openstack_juno-opnfv2/ansible.log ./ &> /dev/null
+ sshpass -p root scp 2>/dev/null $ssh_options root@${installer_ip}:/var/ansible/run/openstack_${COMPASS_OPENSTACK_VERSION}-opnfv2/ansible.log ./ &> /dev/null
exit $deploy_ret
gsutil cp $BUILD_DIRECTORY/opnfv.properties gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.properties > gsutil.properties.log 2>&1
gsutil cp $BUILD_DIRECTORY/opnfv.properties gs://$GS_URL/latest.properties > gsutil.latest.log 2>&1
-
echo
echo "--------------------------------------------------------"
echo "Done!"