aboutsummaryrefslogtreecommitdiffstats
path: root/jjb/ci-management
diff options
context:
space:
mode:
authorAnil Belur <abelur@linuxfoundation.org>2017-05-24 19:20:50 +1000
committerAnil Belur <abelur@linuxfoundation.org>2017-06-16 10:00:34 +1000
commita32358763fecf10bda78806374aba34b51befcf9 (patch)
tree3cb9548a3f6991cf79ddc89c9af0aa9b9c29b2ff /jjb/ci-management
parenta071b7895b5eaf1967a26a43c0d61746576edbf1 (diff)
Add packer verify and merge jobs for AGL
Packer jobs are designed to rebuild new minon images regularly. These jobs are also triggered on changes submitted to the templates or provision scripts. New images generated by packer must be manually updated on Jenkins. Change-Id: Ie2e7dbcbc57148693ad1cf4179ceda2f7a3c9d1a Signed-off-by: Anil Belur <abelur@linuxfoundation.org>
Diffstat (limited to 'jjb/ci-management')
-rw-r--r--jjb/ci-management/ci-management.yaml132
1 files changed, 131 insertions, 1 deletions
diff --git a/jjb/ci-management/ci-management.yaml b/jjb/ci-management/ci-management.yaml
index a519b75f..07811ea5 100644
--- a/jjb/ci-management/ci-management.yaml
+++ b/jjb/ci-management/ci-management.yaml
@@ -4,10 +4,20 @@
jobs:
- 'ci-management-verify-jjb'
- 'ci-management-merge'
+ - 'ci-management-verify-packer'
+ - 'ci-management-merge-packer-{platforms}-{templates}'
project: 'ci-management'
branch: master
+ platforms:
+ - ubuntu-16.04
+
+ templates:
+ - basebuild-agl-test-slave
+ - basebuild-control-slave
+ - basebuild
+
- job-template:
name: ci-management-verify-jjb
@@ -35,6 +45,7 @@
- gerrit-trigger-patch-submitted:
name: '{project}'
branch: '{branch}'
+ files: '**/**'
builders:
- shell: |
@@ -65,7 +76,7 @@
choosing-strategy: 'default'
wrappers:
- - agl-infra-wrappers:
+ - agl-infra-wrappers:
build-timeout: '{build-timeout}'
triggers:
@@ -76,3 +87,122 @@
builders:
- shell:
!include-raw-escape: include-raw-jjb-update.sh
+
+
+- job-template:
+ name: 'ci-management-verify-packer'
+ project-type: freestyle
+ node: control-slave
+ concurrent: true
+
+ properties:
+ - agl-infra-properties:
+ build-days-to-keep: '{build-days-to-keep}'
+ build-num-to-keep: '{build-num-to-keep}'
+
+
+ parameters:
+ - agl-infra-parameters:
+ project: '{project}'
+ branch: 'master'
+ refspec: 'refs/heads/master'
+
+ scm:
+ - gerrit-trigger-scm:
+ refspec: '$GERRIT_REFSPEC'
+ choosing-strategy: 'gerrit'
+
+ wrappers:
+ - agl-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ - gerrit-trigger-patch-submitted:
+ name: 'AGL/AGL-repo'
+ branch: '{branch}'
+ files: 'packer/**'
+
+ builders:
+ - packer-validate:
+
+ publishers:
+ - archive:
+ artifacts: 'packer/*.log'
+ allow-empty: 'true'
+ only-if-success: 'true'
+
+- job-template:
+ name: 'ci-management-merge-packer-{platforms}-{templates}'
+ project-type: freestyle
+ node: control-slave
+
+ properties:
+ - agl-infra-properties:
+ build-days-to-keep: '{build-days-to-keep}'
+ build-num-to-keep: '{build-num-to-keep}'
+
+ parameters:
+ - agl-infra-parameters:
+ project: '{project}'
+ branch: 'master'
+ refspec: 'refs/heads/master'
+
+ scm:
+ - gerrit-trigger-scm:
+ refspec: '$GERRIT_REFSPEC'
+ choosing-strategy: 'gerrit'
+
+ wrappers:
+ - ssh-agent-credentials:
+ users:
+ - '{ssh-credentials}'
+ - agl-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ - timed: '00 10 1 * *'
+ - gerrit:
+ trigger-on:
+ - change-merged-event
+ - comment-added-contains-event:
+ comment-contains-value: 'remerge'
+ projects:
+ - project-compare-type: 'ANT'
+ project-pattern: 'ci-management'
+ branches:
+ - branch-compare-type: 'ANT'
+ branch-pattern: '**/{branch}'
+ file-paths:
+ - compare-type: ANT
+ pattern: 'packer/vars/{platforms}.json'
+ - compare-type: ANT
+ pattern: 'packer/templates/{templates}.json'
+ - compare-type: ANT
+ pattern: 'packer/provision/{templates}.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/system_reseal.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/rh-user_data.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/baseline.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/null_data.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/agl_dependencies.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/agl_mirror.sh'
+ - compare-type: ANT
+ pattern: 'packer/provision/basebuild-no-tmpfs.sh'
+
+
+ builders:
+ - packer-validate:
+ - packer-build:
+ platform: '{platforms}'
+ template: '{templates}'
+
+ publishers:
+ - archive:
+ artifacts: 'packer/*.log'
+ allow-empty: 'true'
+ only-if-success: 'true'