diff options
author | 2017-01-11 15:16:44 +0530 | |
---|---|---|
committer | 2017-02-03 18:25:35 +0000 | |
commit | 175422b27358c428c9e6368b66668fe8b19703bb (patch) | |
tree | c77439849adc25cb59e07ff5924602993f33b9e2 /jjb/releng/testapi-automate.yml | |
parent | c114aac1803c41d00f64ff1af07b1355eafe3390 (diff) |
Adding multijob builder and script for deploy of testapi
docker-update and generate-doc will run in opnfv-build defaults, and
docker-deploy will run in testresults.
Script will ensure this :-
Docker Images in testresults.opnfv.org
- N-1 docker image will be labeled as stable.
- N docker image will be latest.
Docker containers
- N-1 container will be stopped but not removed but will be removed in next iteration.
JIRA: FUNCTEST-689
Change-Id: I8c66ff716bae969b34fe698cdfa6140ef494ec49
Signed-off-by: rohitsakala <rohitsakala@gmail.com>
Diffstat (limited to 'jjb/releng/testapi-automate.yml')
-rw-r--r-- | jjb/releng/testapi-automate.yml | 116 |
1 files changed, 108 insertions, 8 deletions
diff --git a/jjb/releng/testapi-automate.yml b/jjb/releng/testapi-automate.yml index 47d217e51..4d450f35c 100644 --- a/jjb/releng/testapi-automate.yml +++ b/jjb/releng/testapi-automate.yml @@ -4,8 +4,18 @@ - master: branch: '{stream}' gs-pathname: '' + + phase: + - 'docker-update': + slave-label: 'opnfv-build' + - 'docker-deploy': + slave-label: 'testresults' + - 'generate-doc': + slave-label: 'opnfv-build' + jobs: - 'testapi-automate-{stream}' + - 'testapi-automate-{phase}-{stream}' - 'testapi-verify-{stream}' project: 'releng' @@ -15,6 +25,11 @@ slave-label: 'testresults' + parameters: + - project-parameter: + project: '{project}' + branch: '{branch}' + scm: - git-scm @@ -80,10 +95,20 @@ healthy: 50 unhealthy: 40 failing: 30 + - 'email-publisher' - job-template: name: 'testapi-automate-{stream}' + project-type: multijob + + properties: + - throttle: + enabled: true + max-total: 1 + max-per-node: 1 + option: 'project' + parameters: - project-parameter: project: '{project}' @@ -97,6 +122,12 @@ scm: - git-scm + wrappers: + - ssh-agent-wrapper + - timeout: + timeout: 360 + fail: true + triggers: - gerrit: server-name: 'gerrit.opnfv.org' @@ -112,12 +143,57 @@ branch-pattern: '**/{branch}' file-paths: - compare-type: 'ANT' - pattern: 'utils/**' + pattern: 'utils/test/testapi/**' builders: - - docker-update - - testapi-doc-build - - upload-doc-artifact + - multijob: + name: docker-update + condition: SUCCESSFUL + projects: + - name: 'testapi-automate-docker-update-{stream}' + current-parameters: true + kill-phase-on: FAILURE + abort-all-job: true + - multijob: + name: docker-deploy + condition: SUCCESSFUL + projects: + - name: 'testapi-automate-docker-deploy-{stream}' + current-parameters: true + kill-phase-on: FAILURE + abort-all-job: true + - multijob: + name: generate-doc + condition: SUCCESSFUL + projects: + - name: 'testapi-automate-generate-doc-{stream}' + current-parameters: true + kill-phase-on: FAILURE + abort-all-job: true + + publishers: + - 'email-publisher' + +- job-template: + name: 'testapi-automate-{phase}-{stream}' + + properties: + - throttle: + enabled: true + max-per-node: 1 + option: 'project' + + wrappers: + - ssh-agent-wrapper + - timeout: + timeout: 120 + fail: true + + scm: + - git-scm + + builders: + - 'testapi-automate-{phase}-macro' ################################ # job builders @@ -129,25 +205,49 @@ bash ./jjb/releng/testapi-backup-mongodb.sh - builder: - name: run-unit-tests + name: 'run-unit-tests' builders: - shell: | bash ./utils/test/testapi/run_test.sh - builder: - name: docker-update + name: 'testapi-automate-docker-update-macro' builders: - shell: | bash ./jjb/releng/testapi-docker-update.sh - builder: - name: testapi-doc-build + name: 'testapi-automate-generate-doc-macro' + builders: + - 'testapi-doc-build' + - 'upload-doc-artifact' + +- builder: + name: 'testapi-doc-build' builders: - shell: | bash ./utils/test/testapi/htmlize/doc-build.sh - builder: - name: upload-doc-artifact + name: 'upload-doc-artifact' builders: - shell: | bash ./utils/test/testapi/htmlize/push-doc-artifact.sh + +- builder: + name: 'testapi-automate-docker-deploy-macro' + builders: + - shell: | + bash ./jjb/releng/testapi-docker-deploy.sh + +################################ +# job publishers +################################ + +- publisher: + name: 'email-publisher' + publishers: + - email: + recipients: rohitsakala@gmail.com serena.feng.711@gmail.com + notify-every-unstable-build: false + send-to-individuals: true
\ No newline at end of file |