Consolidate common CSIT job-config into anchor 45/77745/7
authorThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 14 Nov 2018 01:41:09 +0000 (09:41 +0800)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Thu, 29 Nov 2018 06:35:32 +0000 (14:35 +0800)
Consolidates the following CSIT job-configs into a common anchor
for simplified management:

    - project-type
    - node
    - concurrent
    - disabled
    - properties

and call the inttest_csit_common anchor in all CSIT templates to pull
these values in.

Change-Id: I4444ab5a89fbbb7e6ce2fe56440c852bf487f194
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
jjb/integration/integration-templates.yaml

index 266782c128804495ce8ad8c33e21e8ef9898bd2d..c02b92d961366d1ab611d52f508afe6e71455e49 100644 (file)
 # integration-use-features-boot: bool to toggle use of featuresBoot ($USEFEATURESBOOT)
 
 
-# New templates
+###########
+# Anchors #
+###########
 
-- job-template:
-    name: '{prefix}{project}-csit-verify-1node-{functionality}'
-    id: inttest-csit-verify-1node
-    disabled: false
+- inttest_csit_common: &inttest_csit_common
+    name: inttest-csit-common
+    # Defines common configuration to all CSIT jobs
+
+    #####################
+    # Default variables #
+    #####################
+
+    build-days-to-keep: 30
+    disable-job: false
+
+    #####################
+    # Job configuration #
+    #####################
 
     project-type: freestyle
     node: centos7-robot-2c-8g
+    concurrent: true
+    disabled: '{disable-job}'
 
     properties:
       - opendaylight-infra-properties:
           build-days-to-keep: '{build-days-to-keep}'
 
+
+#################
+# Job Templates #
+#################
+
+- job-template:
+    name: '{prefix}{project}-csit-verify-1node-{functionality}'
+    id: inttest-csit-verify-1node
+    <<: *inttest_csit_common
+
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
     # Default variables #
     #####################
 
-    disable-job: false
+    # TODO: Add default variables here.
 
     #####################
     # Job configuration #
     #####################
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
-    concurrent: true
-    disabled: '{disable-job}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
-
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
 - job-template:
     name: '{prefix}{project}-csit-1node-{functionality}-{install}-{stream}'
     id: inttest-csit-1node
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_1node
 
 - job-template:
     name: '{prefix}{project}-csit-1node-{functionality}-{install}-{stream}'
     id: inttest-csit-1node-custom
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_1node
 
     parameters:
 - job-template:
     name: '{prefix}{project}-csit-verify-3node-{functionality}'
     id: inttest-csit-verify-3node
-    disabled: false
+    <<: *inttest_csit_common
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
+    #####################
+    # Default variables #
+    #####################
 
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
+    # TODO: Add default variables here
+
+    #####################
+    # Job Configuration #
+    #####################
 
     parameters:
       - opendaylight-infra-parameters:
     # Default variables #
     #####################
 
-    disable-job: false
+    # TODO: Add default variables here
 
     #####################
     # Job configuration #
     #####################
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
-    concurrent: true
-    disabled: '{disable-job}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
-
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
 - job-template:
     name: '{prefix}{project}-csit-3node-{functionality}-{install}-{stream}'
     id: inttest-csit-3node
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_3node
 
 - job-template:
     name: '{prefix}{project}-csit-3node-{functionality}-{install}-{stream}'
     id: inttest-csit-3node-custom
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_3node
 
     parameters:
 - job-template:
     name: '{prefix}{project}-csit-3node-docker-{functionality}-{install}-{stream}'
     id: inttest-csit-3node-docker
-    disabled: false
+    <<: *inttest_csit_common
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
+    #####################
+    # Default variables #
+    #####################
 
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
+    # TODO: Add default variables here
+
+    #####################
+    # Job Configuration #
+    #####################
 
     parameters:
       - opendaylight-infra-parameters:
     # Default variables #
     #####################
 
-    disable-job: false
+    # TODO: Add default variables here
 
     #####################
     # Job configuration #
     #####################
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
-    concurrent: true
-    disabled: '{disable-job}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
-
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-hwvtep-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-openstack-{openstack}-{functionality}-{stream}'
     id: inttest-csit-hwvtep-openstack
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_hwvtep_openstack
 
 - job-template:
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-hwvtep-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-openstack-{openstack}-{functionality}-{stream}'
     id: inttest-csit-hwvtep-openstack-custom
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_hwvtep_openstack
 
     parameters:
     # Default variables #
     #####################
 
-    disable-job: false
+    # TODO: Add default variables here
 
     #####################
     # Job configuration #
     #####################
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
-    concurrent: true
-    disabled: '{disable-job}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
-
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-openstack-{openstack}-{functionality}-{stream}'
     id: inttest-csit-openstack
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_openstack
 
 - job-template:
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-openstack-{openstack}-{functionality}-{stream}'
     id: inttest-csit-openstack-custom
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_openstack
 
     parameters:
 - job-template:
     name: '{prefix}{project}-patch-test-{feature}-{stream}'
     id: inttest-patch-test
-
-    project-type: freestyle
-    node: centos7-builder-2c-8g
-    concurrent: true
-    jdk: '{java-version}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
+    <<: *inttest_csit_common
 
     parameters:
       - opendaylight-infra-parameters:
     # Default variables #
     #####################
 
-    disable-job: false
+    # TODO: Add default variables here
 
     #####################
     # Job configuration #
     #####################
 
-    project-type: freestyle
-    node: centos7-robot-2c-8g
-    concurrent: true
-    disabled: '{disable-job}'
-
-    properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
-
     parameters:
       - opendaylight-infra-parameters:
           os-cloud: '{os-cloud}'
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-apex-{openstack}-{functionality}-{stream}'
     id: inttest-csit-apex
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_apex
 
 - job-template:
     # yamllint disable-line rule:line-length
     name: '{prefix}{project}-csit-{topology}-{os-cmb-cnt}cmb-{os-ctl-cnt}ctl-{os-cmp-cnt}cmp-apex-{openstack}-{functionality}-{stream}'
     id: inttest-csit-apex-custom
+    <<: *inttest_csit_common
+    # yamllint disable-line rule:key-duplicates
     <<: *inttest_csit_apex
 
     parameters: