diff options
author | Fatih Degirmenci <fatih.degirmenci@ericsson.com> | 2016-07-13 10:29:40 +0200 |
---|---|---|
committer | Fatih Degirmenci <fatih.degirmenci@ericsson.com> | 2016-07-13 10:29:40 +0200 |
commit | 245eabf87b5c9085dbe7a9ed8702a5bf7991ff68 (patch) | |
tree | a58edd43c53c196d8ec28db16ef020cd845c7b26 /jjb | |
parent | 39adf3b611ff01fbd38dcdf7336260a84e64c3ae (diff) |
sandbox: Introduce dependency between verify jobs
Change-Id: I227e4584685941377052465459962ea99f3e7bfb
Signed-off-by: Fatih Degirmenci <fatih.degirmenci@ericsson.com>
Diffstat (limited to 'jjb')
-rwxr-xr-x | jjb/sandbox/basic.sh | 2 | ||||
-rwxr-xr-x | jjb/sandbox/build.sh | 2 | ||||
-rwxr-xr-x | jjb/sandbox/deploy.sh | 2 | ||||
-rw-r--r-- | jjb/sandbox/sandbox-verify-jobs.yml | 165 | ||||
-rwxr-xr-x | jjb/sandbox/test.sh | 2 | ||||
-rwxr-xr-x | jjb/sandbox/verify.sh | 29 |
6 files changed, 64 insertions, 138 deletions
diff --git a/jjb/sandbox/basic.sh b/jjb/sandbox/basic.sh index 2f9be2729..33268558c 100755 --- a/jjb/sandbox/basic.sh +++ b/jjb/sandbox/basic.sh @@ -59,3 +59,5 @@ echo "git show" echo "-------------------------------------" git show echo "-------------------------------------" + +sleep 60 diff --git a/jjb/sandbox/build.sh b/jjb/sandbox/build.sh index 2f9be2729..33268558c 100755 --- a/jjb/sandbox/build.sh +++ b/jjb/sandbox/build.sh @@ -59,3 +59,5 @@ echo "git show" echo "-------------------------------------" git show echo "-------------------------------------" + +sleep 60 diff --git a/jjb/sandbox/deploy.sh b/jjb/sandbox/deploy.sh index 2f9be2729..33268558c 100755 --- a/jjb/sandbox/deploy.sh +++ b/jjb/sandbox/deploy.sh @@ -59,3 +59,5 @@ echo "git show" echo "-------------------------------------" git show echo "-------------------------------------" + +sleep 60 diff --git a/jjb/sandbox/sandbox-verify-jobs.yml b/jjb/sandbox/sandbox-verify-jobs.yml index a899193d7..face67041 100644 --- a/jjb/sandbox/sandbox-verify-jobs.yml +++ b/jjb/sandbox/sandbox-verify-jobs.yml @@ -4,32 +4,69 @@ project: 'sandbox' installer: 'sandbox' - +##################################### +# branch definitions +##################################### stream: - master: branch: '{stream}' gs-pathname: '' - -# what are the verification activities we do for this installer + disabled: false + - colorado: + branch: 'stable/{stream}' + gs-pathname: '/{stream}' + disabled: true +##################################### +# patch verification activities +##################################### activity: - - 'basic' - - 'build' - - 'deploy' - - 'test' - + - 'basic': + dependency-jobs: '' + slave-label: 'opnfv-build-ubuntu' + - 'build': + dependency-jobs: 'sandbox-verify-basic-{stream}' + slave-label: 'opnfv-build-ubuntu' + - 'deploy': + dependency-jobs: 'sandbox-verify-build-{stream}' + slave-label: 'sandbox-virtual' + - 'test': + dependency-jobs: 'sandbox-verify-deploy-{stream}' + slave-label: 'sandbox-virtual' +##################################### +# jobs +##################################### jobs: - - 'sandbox-verify-{stream}' - 'sandbox-verify-{activity}-{stream}' - +##################################### +# job templates +##################################### - job-template: - name: 'sandbox-verify-{stream}' + name: 'sandbox-verify-{activity}-{stream}' + + disabled: '{obj:disabled}' + + concurrent: true + + properties: + - build-blocker: + use-build-blocker: true + blocking-jobs: + - 'sandbox-verify-deploy-.*' + - 'sandbox-verify-test-.*' + block-level: 'NODE' parameters: - project-parameter: project: '{project}' - gerrit-parameter: branch: '{branch}' - - 'opnfv-build-ubuntu-defaults' + - '{slave-label}-defaults' + + scm: + - gerrit-trigger-scm: + credentials-id: '{ssh-credentials}' + refspec: '$GERRIT_REFSPEC' + choosing-strategy: 'gerrit' wrappers: - ssh-agent-credentials: @@ -61,125 +98,35 @@ - compare-type: ANT pattern: 'docs/**|.gitignore' readable-message: true + dependency-jobs: '{dependency-jobs}' builders: - description-setter: description: "Built on $NODE_NAME" - - '{project}-verify-builder' - - trigger-builds: - - project: 'sandbox-verify-basic-{stream}' - current-parameters: false - predefined-parameters: | - GERRIT_BRANCH=$GERRIT_BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - block: true - - trigger-builds: - - project: 'sandbox-verify-build-{stream}' - current-parameters: false - predefined-parameters: | - GERRIT_BRANCH=$GERRIT_BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - block: true - - trigger-builds: - - project: 'sandbox-verify-deploy-{stream}' - current-parameters: false - predefined-parameters: | - GERRIT_BRANCH=$GERRIT_BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - block: true - - trigger-builds: - - project: 'sandbox-verify-test-{stream}' - current-parameters: false - predefined-parameters: | - GERRIT_BRANCH=$GERRIT_BRANCH - GERRIT_REFSPEC=$GERRIT_REFSPEC - GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER - block: true - -- job-template: - name: 'sandbox-verify-{activity}-{stream}' - - scm: - - gerrit-trigger-scm: - credentials-id: '{ssh-credentials}' - refspec: '$GERRIT_REFSPEC' - choosing-strategy: 'gerrit' - - wrappers: - - ssh-agent-credentials: - users: - - '{ssh-credentials}' - - timeout: - timeout: 360 - fail: true - - parameters: - - project-parameter: - project: '{project}' - - gerrit-parameter: - branch: '{branch}' - - '{installer}-defaults' - - '{project}-verify-{activity}-parameter' - - builders: - - description-setter: - description: "Built on $NODE_NAME" - - '{project}-verify-{activity}-builder' - + - '{project}-verify-{activity}-macro' ##################################### -# parameter builders +# builder macros ##################################### -- parameter: - name: 'sandbox-verify-basic-parameter' - parameters: - - 'opnfv-build-ubuntu-defaults' - -- parameter: - name: 'sandbox-verify-build-parameter' - parameters: - - 'opnfv-build-ubuntu-defaults' - -- parameter: - name: 'sandbox-verify-deploy-parameter' - parameters: - - 'opnfv-build-centos-defaults' - -- parameter: - name: 'sandbox-verify-test-parameter' - parameters: - - 'opnfv-build-centos-defaults' -##################################### -# builder builders -##################################### -- builder: - name: 'sandbox-verify-builder' - builders: - - shell: - !include-raw: ./verify.sh - - builder: - name: 'sandbox-verify-basic-builder' + name: 'sandbox-verify-basic-macro' builders: - shell: !include-raw: ./basic.sh - builder: - name: 'sandbox-verify-build-builder' + name: 'sandbox-verify-build-macro' builders: - shell: !include-raw: ./build.sh - builder: - name: 'sandbox-verify-deploy-builder' + name: 'sandbox-verify-deploy-macro' builders: - shell: !include-raw: ./deploy.sh - builder: - name: 'sandbox-verify-test-builder' + name: 'sandbox-verify-test-macro' builders: - shell: !include-raw: ./test.sh diff --git a/jjb/sandbox/test.sh b/jjb/sandbox/test.sh index 2f9be2729..33268558c 100755 --- a/jjb/sandbox/test.sh +++ b/jjb/sandbox/test.sh @@ -59,3 +59,5 @@ echo "git show" echo "-------------------------------------" git show echo "-------------------------------------" + +sleep 60 diff --git a/jjb/sandbox/verify.sh b/jjb/sandbox/verify.sh deleted file mode 100755 index f62d2b977..000000000 --- a/jjb/sandbox/verify.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/bash - -# this is where we check the commit message, unit test, etc. -cd $WORKSPACE -echo -echo "Commit Message is" -echo "-------------------------------------" -git log --format=%B -n 1 $(git rev-parse HEAD) -echo "-------------------------------------" -echo -echo "Repo contents" -echo "-------------------------------------" -ls -al -echo "-------------------------------------" -echo -echo "Changed files are" -echo "-------------------------------------" -git diff origin/master --name-only -echo "-------------------------------------" -echo -echo "Change introduced" -echo "-------------------------------------" -git diff origin/master -echo "-------------------------------------" -echo -echo "git show" -echo "-------------------------------------" -git show -echo "-------------------------------------" |