Merge "add testapi-client verify job"
authorSerena Feng <feng.xiaowei@zte.com.cn>
Fri, 2 Mar 2018 05:46:36 +0000 (05:46 +0000)
committerGerrit Code Review <gerrit@opnfv.org>
Fri, 2 Mar 2018 05:46:36 +0000 (05:46 +0000)
18 files changed:
jjb/armband/armband-ci-jobs.yml
jjb/compass4nfv/compass-ci-jobs.yml
jjb/fuel/fuel-daily-jobs.yml
jjb/functest/functest-k8.sh
jjb/functest/functest-kubernetes-project-jobs.yml [new file with mode: 0644]
jjb/functest/xtesting-project-jobs.yml [new file with mode: 0644]
jjb/qtip/qtip-validate-jobs.yml
jjb/releng/opnfv-docker.sh
jjb/releng/opnfv-docker.yml
jjb/xci/bifrost-verify.sh
jjb/xci/osa-periodic-jobs.yml
jjb/xci/xci-cleanup.sh
jjb/xci/xci-run-functest.sh
jjb/xci/xci-set-scenario.sh
jjb/xci/xci-start-deployment.sh
jjb/yardstick/yardstick-daily-jobs.yml
jjb/yardstick/yardstick-project-jobs.yml
utils/fetch_k8_conf.sh

index da3992e..64c1389 100644 (file)
@@ -62,6 +62,8 @@
           auto-trigger-name: '{installer}-{scenario}-{pod}-{stream}-trigger'
       - 'os-odl-nofeature-ha':
           auto-trigger-name: '{installer}-{scenario}-{pod}-{stream}-trigger'
+      - 'os-nosdn-ovs-ha':
+          auto-trigger-name: '{installer}-{scenario}-{pod}-{stream}-trigger'
 
       # NOHA scenarios
       - 'os-nosdn-nofeature-noha':
                     failure-threshold: 'never'
                     unstable-threshold: 'FAILURE'
       # 1.here the stream means the SUT stream, dovetail stream is defined in its own job
-      # 2.only debug testsuite here(refstack, ha, vping, ipv6, tempest, bgpvpn)
-      # 3.not used for release criteria or compliance,
+      # 2.testsuite proposed_tests here is for new test cases planning to add into OVP
+      # 3.run proposed_tests on Monday, Wednesday and Friday against ha scenario
+      # 4.testsuite default here is for the test cases already added into OVP
+      # 5.run default testsuite on Tuesday against ha scenario
+      # 6.not used for release criteria or compliance,
       #   only to debug the dovetail tool bugs with arm pods
-      - trigger-builds:
-          - project: 'dovetail-{installer}-{pod}-proposed_tests-{stream}'
-            current-parameters: false
-            predefined-parameters:
-              DEPLOY_SCENARIO={scenario}
-            block: true
-            same-node: true
-            block-thresholds:
-              build-step-failure-threshold: 'never'
-              failure-threshold: 'never'
-              unstable-threshold: 'FAILURE'
+      - conditional-step:
+          condition-kind: and
+          condition-operands:
+            - condition-kind: regex-match
+              regex: '-ha$'
+              label: '{scenario}'
+            - condition-kind: day-of-week
+              day-selector: select-days
+              days:
+                MON: true
+                WED: true
+                FRI: true
+              use-build-time: true
+          steps:
+            - trigger-builds:
+                - project: 'dovetail-{installer}-{pod}-proposed_tests-{stream}'
+                  current-parameters: false
+                  predefined-parameters:
+                    DEPLOY_SCENARIO={scenario}
+                  block: true
+                  same-node: true
+                  block-thresholds:
+                    build-step-failure-threshold: 'never'
+                    failure-threshold: 'never'
+                    unstable-threshold: 'FAILURE'
+      - conditional-step:
+          condition-kind: and
+          condition-operands:
+            - condition-kind: regex-match
+              regex: '*-ha'
+              label: '{scenario}'
+            - condition-kind: day-of-week
+              day-selector: select-days
+              days:
+                TUES: true
+              use-build-time: true
+          steps:
+            - trigger-builds:
+                - project: 'dovetail-{installer}-{pod}-default-{stream}'
+                  current-parameters: false
+                  predefined-parameters:
+                    DEPLOY_SCENARIO={scenario}
+                  block: true
+                  same-node: true
+                  block-thresholds:
+                    build-step-failure-threshold: 'never'
+                    failure-threshold: 'never'
+                    unstable-threshold: 'FAILURE'
       # Armband uses Fuel's log collection project job, no need to duplicate
       - conditional-step:
           condition-kind: not
 - trigger:
     name: 'fuel-os-nosdn-nofeature-ha-armband-baremetal-master-trigger'
     triggers:
-      - timed: '0 1 * * 2,4,6'
+      - timed: '0 1 * * 4,6'
 - trigger:
     name: 'fuel-os-nosdn-nofeature-noha-armband-baremetal-master-trigger'
     triggers:
 - trigger:
     name: 'fuel-os-odl-nofeature-ha-armband-baremetal-master-trigger'
     triggers:
-      - timed: '0 1 * * 1,3,5,7'
+      - timed: '0 1 * * 2,5,7'
+- trigger:
+    name: 'fuel-os-nosdn-ovs-ha-armband-baremetal-master-trigger'
+    triggers:
+      - timed: '0 1 * * 1,3'
 # ---------------------------------------------------------------------
 # Enea Armband CI Baremetal Triggers running against euphrates branch
 # ---------------------------------------------------------------------
     name: 'fuel-os-odl-nofeature-ha-armband-baremetal-euphrates-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'fuel-os-nosdn-ovs-ha-armband-baremetal-euphrates-trigger'
+    triggers:
+      - timed: ''
+
 # --------------------------------------------------------------
 # Enea Armband CI Virtual Triggers running against master branch
 # --------------------------------------------------------------
     name: 'fuel-os-odl-nofeature-ha-armband-virtual-master-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'fuel-os-nosdn-ovs-ha-armband-virtual-master-trigger'
+    triggers:
+      - timed: ''
 # -------------------------------------------------------------------
 # Enea Armband CI Virtual Triggers running against euphrates branch
 # -------------------------------------------------------------------
     name: 'fuel-os-odl-nofeature-ha-armband-virtual-euphrates-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'fuel-os-nosdn-ovs-ha-armband-virtual-euphrates-trigger'
+    triggers:
+      - timed: ''
index 7ce9e3a..357f24e 100644 (file)
       - 'os-nosdn-bar-ha':
           disabled: false
           auto-trigger-name: 'compass-{scenario}-{pod}-{stream}-trigger'
+      - 'os-nosdn-bar-noha':
+          disabled: false
+          auto-trigger-name: 'compass-{scenario}-{pod}-{stream}-trigger'
       - 'k8-nosdn-stor4nfv-ha':
           disabled: false
           auto-trigger-name: 'compass-{scenario}-{pod}-{stream}-trigger'
     name: 'compass-os-nosdn-ovs_dpdk-noha-baremetal-centos-master-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-baremetal-centos-master-trigger'
+    triggers:
+      - timed: ''  # '0 19 * * *'
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-baremetal-centos-master-trigger'
     triggers:
     name: 'compass-os-nosdn-ovs_dpdk-noha-huawei-pod7-danube-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-huawei-pod7-danube-trigger'
+    triggers:
+      - timed: ''  # '0 19 * * *'
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-huawei-pod7-danube-trigger'
     triggers:
     name: 'compass-os-nosdn-ovs_dpdk-noha-baremetal-master-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-baremetal-master-trigger'
+    triggers:
+      - timed: ''
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-baremetal-master-trigger'
     triggers:
     name: 'compass-os-nosdn-ovs_dpdk-noha-baremetal-euphrates-trigger'
     triggers:
       - timed: ''
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-baremetal-euphrates-trigger'
+    triggers:
+      - timed: ''
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-baremetal-euphrates-trigger'
     triggers:
     name: 'compass-os-nosdn-ovs_dpdk-noha-virtual-master-trigger'
     triggers:
       - timed: '0 11 2-30/2 * *'
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-virtual-master-trigger'
+    triggers:
+      - timed: '0 22 1-29/2 * *'
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-virtual-master-trigger'
     triggers:
     name: 'compass-os-nosdn-ovs_dpdk-noha-virtual-euphrates-trigger'
     triggers:
       - timed: '0 12 2-30/2 * *'
+- trigger:
+    name: 'compass-os-nosdn-bar-noha-virtual-euphrates-trigger'
+    triggers:
+      - timed: '0 12 1-29/2 * *'
 - trigger:
     name: 'compass-k8-nosdn-stor4nfv-noha-virtual-euphrates-trigger'
     triggers:
index bbc8a84..f4bcdaa 100644 (file)
                     failure-threshold: 'never'
                     unstable-threshold: 'FAILURE'
       # 1.here the stream means the SUT stream, dovetail stream is defined in its own job
-      # 2.only debug testsuite here(refstack, ha, vping, ipv6, tempest, bgpvpn)
-      # 3.not used for release criteria or compliance, only to debug the dovetail tool bugs
-      # 4.ZTE pod1, os-nosdn-nofeature-ha and os-odl-bgpvpn-ha, run against danube
-      - trigger-builds:
-          - project: 'dovetail-fuel-{pod}-proposed_tests-{stream}'
-            current-parameters: false
-            predefined-parameters:
-              DEPLOY_SCENARIO={scenario}
-            block: true
-            same-node: true
-            block-thresholds:
-              build-step-failure-threshold: 'never'
-              failure-threshold: 'never'
-              unstable-threshold: 'FAILURE'
+      # 2.testsuite proposed_tests here is for new test cases planning to add into OVP
+      # 3.run proposed_tests on Monday, Wednesday and Friday against ha scenario
+      # 4.testsuite default here is for the test cases already added into OVP
+      # 5.run default testsuite on Tuesday against ha scenario
+      # 6.not used for release criteria or compliance, only to debug the dovetail tool bugs
+      - conditional-step:
+          condition-kind: and
+          condition-operands:
+            - condition-kind: regex-match
+              regex: '-ha$'
+              label: '{scenario}'
+            - condition-kind: day-of-week
+              day-selector: select-days
+              days:
+                MON: true
+                WED: true
+                FRI: true
+              use-build-time: true
+          steps:
+            - trigger-builds:
+                - project: 'dovetail-fuel-{pod}-proposed_tests-{stream}'
+                  current-parameters: false
+                  predefined-parameters:
+                    DEPLOY_SCENARIO={scenario}
+                  block: true
+                  same-node: true
+                  block-thresholds:
+                    build-step-failure-threshold: 'never'
+                    failure-threshold: 'never'
+                    unstable-threshold: 'FAILURE'
+      - conditional-step:
+          condition-kind: and
+          condition-operands:
+            - condition-kind: regex-match
+              regex: '*-ha'
+              label: '{scenario}'
+            - condition-kind: day-of-week
+              day-selector: select-days
+              days:
+                TUES: true
+              use-build-time: true
+          steps:
+            - trigger-builds:
+                - project: 'dovetail-fuel-{pod}-default-{stream}'
+                  current-parameters: false
+                  predefined-parameters:
+                    DEPLOY_SCENARIO={scenario}
+                  block: true
+                  same-node: true
+                  block-thresholds:
+                    build-step-failure-threshold: 'never'
+                    failure-threshold: 'never'
+                    unstable-threshold: 'FAILURE'
       - conditional-step:
           condition-kind: not
           condition-operand:
index 888aded..7c5308d 100755 (executable)
@@ -18,6 +18,9 @@ if [[ ${INSTALLER_TYPE} == 'compass' ]]; then
     echo "export KUBE_MASTER_URL=$KUBE_MASTER_URL" >> $rc_file
     KUBE_MASTER_IP=$(echo $KUBE_MASTER_URL|awk -F'https://|:[0-9]+' '$0=$2')
     echo "export KUBE_MASTER_IP=$KUBE_MASTER_IP" >> $rc_file
+elif [[ ${INSTALLER_TYPE} == 'joid' && ${BRANCH} == 'master' ]]; then
+    admin_conf_file_vol="-v ${HOME}/joid_config/config:/root/joid_config/config"
+    rc_file=${HOME}/joid_config/k8config
 else
     echo "Not supported by other installers yet"
     exit 1
diff --git a/jjb/functest/functest-kubernetes-project-jobs.yml b/jjb/functest/functest-kubernetes-project-jobs.yml
new file mode 100644 (file)
index 0000000..3eba5d1
--- /dev/null
@@ -0,0 +1,257 @@
+---
+###################################################
+# All the jobs except verify have been removed!
+# They will only be enabled on request by projects!
+###################################################
+- project:
+    name: functest-kubernetes-project-jobs
+
+    project: 'functest-kubernetes'
+
+    jobs:
+      - 'functest-kubernetes-verify-{stream}'
+      - 'functest-kubernetes-verify-{phase}-{stream}'
+      - 'functest-kubernetes-docs-upload-{stream}'
+
+    stream:
+      - master:
+          branch: '{stream}'
+          gs-pathname: ''
+          disabled: false
+      - euphrates:
+          branch: 'stable/{stream}'
+          gs-pathname: '/{stream}'
+          disabled: false
+
+    phase:
+      - 'unit-tests-and-docs':
+          slave-label: 'opnfv-build-ubuntu'
+      - 'build-x86_64':
+          slave-label: 'opnfv-build-ubuntu'
+      - 'build-aarch64':
+          slave-label: 'opnfv-build-ubuntu-arm'
+
+- job-template:
+    name: 'functest-kubernetes-verify-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    project-type: 'multijob'
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - 'opnfv-build-ubuntu-defaults'
+
+    scm:
+      - git-scm-gerrit
+
+    triggers:
+      - 'functest-kubernetes-verify-triggers-macro':
+          project: '{project}'
+          branch: '{branch}'
+
+    builders:
+      - shell: |
+          #!/bin/bash
+          # we do nothing here as the main stuff will be done
+          # in phase jobs
+          echo "Triggering phase jobs!"
+      - multijob:
+          name: 'functest-kubernetes-build-and-unittest'
+          execution-type: PARALLEL
+          projects:
+            - name: 'functest-kubernetes-verify-unit-tests-and-docs-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+            - name: 'functest-kubernetes-verify-build-x86_64-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+                ARCH=x86_64
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+            - name: 'functest-kubernetes-verify-build-aarch64-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+                ARCH=aarch64
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+
+- job-template:
+    name: 'functest-kubernetes-verify-{phase}-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    wrappers:
+      - ssh-agent-wrapper
+      - build-timeout:
+          timeout: 30
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - '{slave-label}-defaults'
+
+    scm:
+      - git-scm-gerrit
+
+    builders:
+      - 'functest-kubernetes-verify-{phase}-builders-macro'
+
+    publishers:
+      - 'functest-kubernetes-verify-{phase}-publishers-macro'
+
+- job-template:
+    name: 'functest-kubernetes-docs-upload-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - 'opnfv-build-ubuntu-defaults'
+
+    scm:
+      - git-scm
+
+    triggers:
+      - 'functest-kubernetes-docs-upload-triggers-macro':
+          project: '{project}'
+          branch: '{branch}'
+
+    builders:
+      - functest-kubernetes-upload-doc-artifact
+
+################################
+# job triggers
+################################
+- trigger:
+    name: 'functest-kubernetes-verify-triggers-macro'
+    triggers:
+      - gerrit:
+          server-name: 'gerrit.opnfv.org'
+          trigger-on:
+            - patchset-created-event:
+                exclude-drafts: 'false'
+                exclude-trivial-rebase: 'false'
+                exclude-no-code-change: 'false'
+            - draft-published-event
+            - comment-added-contains-event:
+                comment-contains-value: 'recheck'
+            - comment-added-contains-event:
+                comment-contains-value: 'reverify'
+          projects:
+            - project-compare-type: 'ANT'
+              project-pattern: '{project}'
+              branches:
+                - branch-compare-type: 'ANT'
+                  branch-pattern: '**/{branch}'
+              disable-strict-forbidden-file-verification: 'true'
+              forbidden-file-paths:
+                - compare-type: ANT
+                  pattern: 'docs/**|.gitignore'
+
+- trigger:
+    name: 'functest-kubernetes-docs-upload-triggers-macro'
+    triggers:
+      - gerrit:
+          server-name: 'gerrit.opnfv.org'
+          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: '**/{branch}'
+              disable-strict-forbidden-file-verification: 'true'
+              forbidden-file-paths:
+                - compare-type: ANT
+                  pattern: 'docs/**|.gitignore'
+################################
+# job builders
+################################
+
+- builder:
+    name: 'functest-kubernetes-verify-unit-tests-and-docs-builders-macro'
+    builders:
+      - shell: |
+          cd $WORKSPACE && tox
+
+- builder:
+    name: 'functest-kubernetes-verify-build-x86_64-builders-macro'
+    builders:
+      - shell: |
+          echo "Not activated!"
+
+- builder:
+    name: 'functest-kubernetes-verify-build-aarch64-builders-macro'
+    builders:
+      - shell: |
+          echo "Not activated!"
+
+- builder:
+    name: 'functest-kubernetes-upload-doc-artifact'
+    builders:
+      - shell: |
+          cd $WORKSPACE && tox -edocs
+            wget -O - https://git.opnfv.org/releng/plain/utils/upload-artifact.sh | bash -s "api/_build" "docs"
+################################
+# job publishers
+################################
+- publisher:
+    name: 'functest-kubernetes-verify-unit-tests-and-docs-publishers-macro'
+    publishers:
+      - junit:
+          results: nosetests.xml
+      - cobertura:
+          report-file: "coverage.xml"
+          only-stable: "true"
+          health-auto-update: "true"
+          stability-auto-update: "true"
+          zoom-coverage-chart: "true"
+          targets:
+            - files:
+                healthy: 10
+                unhealthy: 20
+                failing: 30
+            - method:
+                healthy: 50
+                unhealthy: 40
+                failing: 30
+      - email-jenkins-admins-on-failure
+
+- publisher:
+    name: 'functest-kubernetes-verify-build-x86_64-publishers-macro'
+    publishers:
+      - email-jenkins-admins-on-failure
+
+- publisher:
+    name: 'functest-kubernetes-verify-build-aarch64-publishers-macro'
+    publishers:
+      - email-jenkins-admins-on-failure
diff --git a/jjb/functest/xtesting-project-jobs.yml b/jjb/functest/xtesting-project-jobs.yml
new file mode 100644 (file)
index 0000000..bf08775
--- /dev/null
@@ -0,0 +1,257 @@
+---
+###################################################
+# All the jobs except verify have been removed!
+# They will only be enabled on request by projects!
+###################################################
+- project:
+    name: xtesting-project-jobs
+
+    project: 'functest-xtesting'
+
+    jobs:
+      - 'xtesting-verify-{stream}'
+      - 'xtesting-verify-{phase}-{stream}'
+      - 'xtesting-docs-upload-{stream}'
+
+    stream:
+      - master:
+          branch: '{stream}'
+          gs-pathname: ''
+          disabled: false
+      - euphrates:
+          branch: 'stable/{stream}'
+          gs-pathname: '/{stream}'
+          disabled: false
+
+    phase:
+      - 'unit-tests-and-docs':
+          slave-label: 'opnfv-build-ubuntu'
+      - 'build-x86_64':
+          slave-label: 'opnfv-build-ubuntu'
+      - 'build-aarch64':
+          slave-label: 'opnfv-build-ubuntu-arm'
+
+- job-template:
+    name: 'xtesting-verify-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    project-type: 'multijob'
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - 'opnfv-build-ubuntu-defaults'
+
+    scm:
+      - git-scm-gerrit
+
+    triggers:
+      - 'xtesting-verify-triggers-macro':
+          project: '{project}'
+          branch: '{branch}'
+
+    builders:
+      - shell: |
+          #!/bin/bash
+          # we do nothing here as the main stuff will be done
+          # in phase jobs
+          echo "Triggering phase jobs!"
+      - multijob:
+          name: 'xtesting-build-and-unittest'
+          execution-type: PARALLEL
+          projects:
+            - name: 'xtesting-verify-unit-tests-and-docs-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+            - name: 'xtesting-verify-build-x86_64-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+                ARCH=x86_64
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+            - name: 'xtesting-verify-build-aarch64-{stream}'
+              current-parameters: false
+              predefined-parameters: |
+                GERRIT_BRANCH=$GERRIT_BRANCH
+                GERRIT_REFSPEC=$GERRIT_REFSPEC
+                GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
+                GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
+                ARCH=aarch64
+              git-revision: true
+              node-parameters: false
+              kill-phase-on: FAILURE
+              abort-all-job: false
+
+- job-template:
+    name: 'xtesting-verify-{phase}-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    wrappers:
+      - ssh-agent-wrapper
+      - build-timeout:
+          timeout: 30
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - '{slave-label}-defaults'
+
+    scm:
+      - git-scm-gerrit
+
+    builders:
+      - 'xtesting-verify-{phase}-builders-macro'
+
+    publishers:
+      - 'xtesting-verify-{phase}-publishers-macro'
+
+- job-template:
+    name: 'xtesting-docs-upload-{stream}'
+
+    disabled: '{obj:disabled}'
+
+    parameters:
+      - project-parameter:
+          project: '{project}'
+          branch: '{branch}'
+      - 'opnfv-build-ubuntu-defaults'
+
+    scm:
+      - git-scm
+
+    triggers:
+      - 'xtesting-docs-upload-triggers-macro':
+          project: '{project}'
+          branch: '{branch}'
+
+    builders:
+      - xtesting-upload-doc-artifact
+
+################################
+# job triggers
+################################
+- trigger:
+    name: 'xtesting-verify-triggers-macro'
+    triggers:
+      - gerrit:
+          server-name: 'gerrit.opnfv.org'
+          trigger-on:
+            - patchset-created-event:
+                exclude-drafts: 'false'
+                exclude-trivial-rebase: 'false'
+                exclude-no-code-change: 'false'
+            - draft-published-event
+            - comment-added-contains-event:
+                comment-contains-value: 'recheck'
+            - comment-added-contains-event:
+                comment-contains-value: 'reverify'
+          projects:
+            - project-compare-type: 'ANT'
+              project-pattern: '{project}'
+              branches:
+                - branch-compare-type: 'ANT'
+                  branch-pattern: '**/{branch}'
+              disable-strict-forbidden-file-verification: 'true'
+              forbidden-file-paths:
+                - compare-type: ANT
+                  pattern: 'docs/**|.gitignore'
+
+- trigger:
+    name: 'xtesting-docs-upload-triggers-macro'
+    triggers:
+      - gerrit:
+          server-name: 'gerrit.opnfv.org'
+          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: '**/{branch}'
+              disable-strict-forbidden-file-verification: 'true'
+              forbidden-file-paths:
+                - compare-type: ANT
+                  pattern: 'docs/**|.gitignore'
+################################
+# job builders
+################################
+
+- builder:
+    name: 'xtesting-verify-unit-tests-and-docs-builders-macro'
+    builders:
+      - shell: |
+          cd $WORKSPACE && tox
+
+- builder:
+    name: 'xtesting-verify-build-x86_64-builders-macro'
+    builders:
+      - shell: |
+          echo "Not activated!"
+
+- builder:
+    name: 'xtesting-verify-build-aarch64-builders-macro'
+    builders:
+      - shell: |
+          echo "Not activated!"
+
+- builder:
+    name: 'xtesting-upload-doc-artifact'
+    builders:
+      - shell: |
+          cd $WORKSPACE && tox -edocs
+            wget -O - https://git.opnfv.org/releng/plain/utils/upload-artifact.sh | bash -s "api/_build" "docs"
+################################
+# job publishers
+################################
+- publisher:
+    name: 'xtesting-verify-unit-tests-and-docs-publishers-macro'
+    publishers:
+      - junit:
+          results: nosetests.xml
+      - cobertura:
+          report-file: "coverage.xml"
+          only-stable: "true"
+          health-auto-update: "true"
+          stability-auto-update: "true"
+          zoom-coverage-chart: "true"
+          targets:
+            - files:
+                healthy: 10
+                unhealthy: 20
+                failing: 30
+            - method:
+                healthy: 50
+                unhealthy: 40
+                failing: 30
+      - email-jenkins-admins-on-failure
+
+- publisher:
+    name: 'xtesting-verify-build-x86_64-publishers-macro'
+    publishers:
+      - email-jenkins-admins-on-failure
+
+- publisher:
+    name: 'xtesting-verify-build-aarch64-publishers-macro'
+    publishers:
+      - email-jenkins-admins-on-failure
index 3a487fa..5c0bb88 100644 (file)
       - compute:
           installer: apex
           pod: zte-virtual5
+          sut: node
           <<: *master
       - storage:
           installer: apex
           pod: zte-virtual5
+          sut: ''
           <<: *master
       - compute:
           installer: fuel
           pod: zte-virtual6
+          sut: vnf
           <<: *master
 
     # -------------------------------
       - string:
           name: OPNFV_RELEASE
           default: '{stream}'
+      - string:
+          name: SUT
+          description: "System Under Test"
+          default: '{sut}'
     scm:
       - git-scm
 
index 28e5b7c..5c8cafb 100644 (file)
@@ -111,7 +111,7 @@ fi
 echo "Building docker image: $DOCKER_REPO_NAME:$DOCKER_TAG"
 echo "--------------------------------------------------------"
 echo
-cmd="docker build --no-cache -t $DOCKER_REPO_NAME:$DOCKER_TAG --build-arg BRANCH=$BUILD_BRANCH
+cmd="docker build --pull=true --no-cache -t $DOCKER_REPO_NAME:$DOCKER_TAG --build-arg BRANCH=$BUILD_BRANCH
     $ARCH_BUILD_ARG
     -f $DOCKERFILE $DOCKER_PATH"
 
index 317efc8..93b9a9c 100644 (file)
           project: 'yardstick'
           <<: *euphrates
           <<: *other-receivers
+      - 'xtesting':
+          project: 'functest-xtesting'
+          <<: *master
+          <<: *other-receivers
       # projects with jobs for danube
       - 'dovetail':
           project: 'dovetail'
index d3a37ce..9219d00 100755 (executable)
@@ -46,6 +46,6 @@ export XCI_UPDATE_CLEAN_VM_OS=true
 
 ./xci/scripts/vm/start-new-vm.sh $VM_DISTRO
 
-rsync -a -e "ssh -F $HOME/.ssh/xci-vm-config" $WORKSPACE/ ${VM_DISTRO}_xci_vm:~/bifrost
+rsync -a -e "ssh -F $HOME/.ssh/${VM_DISTRO}-xci-vm-config" $WORKSPACE/ ${VM_DISTRO}_xci_vm:~/bifrost
 
-ssh -F $HOME/.ssh/xci-vm-config ${VM_DISTRO}_xci_vm "cd ~/bifrost/releng-xci && ./bifrost_test.sh"
+ssh -F $HOME/.ssh/${VM_DISTRO}-xci-vm-config ${VM_DISTRO}_xci_vm "cd ~/bifrost/releng-xci && ./bifrost_test.sh"
index 64daa69..e604a0a 100644 (file)
       - shell: |
           #!/bin/bash
 
-          ssh -F $HOME/.ssh/xci-vm-config ${DISTRO}_xci_vm "cd releng-xci && ./xci_test.sh"
+          ssh -F $HOME/.ssh/${DISTRO}-xci-vm-config ${DISTRO}_xci_vm "cd releng-xci && ./xci_test.sh"
 
 
 - builder:
       - shell: |
           #!/bin/bash
 
-          sudo virsh destroy ${DISTRO}_xci_vm
-          sudo virsh undefine ${DISTRO}_xci_vm
+          sudo virsh destroy ${DISTRO}_xci_vm || true
+          sudo virsh undefine ${DISTRO}_xci_vm || true
 
 # this will be enabled once the xci is prepared
 # - builder:
index 45b4ec2..ce84830 100755 (executable)
@@ -20,5 +20,5 @@ if [[ "$GERRIT_TOPIC" =~ 'skip-verify' ]]; then
     exit 0
 fi
 
-sudo virsh destroy ${DISTRO}_xci_vm
-sudo virsh undefine ${DISTRO}_xci_vm
+sudo virsh destroy ${DISTRO}_xci_vm || true
+sudo virsh undefine ${DISTRO}_xci_vm || true
index 39d4ea1..238a833 100755 (executable)
@@ -39,4 +39,6 @@ if ! sed -n "/^- scenario: $DEPLOY_SCENARIO$/,/^$/p" $OPNFV_SCENARIO_REQUIREMENT
     exit 0
 fi
 
-ssh -F $HOME/.ssh/xci-vm-config ${DISTRO}_xci_vm "cd releng-xci/xci && PATH=/home/devuser/.local/bin:$PATH ansible-playbook -i installer/osa/files/$XCI_FLAVOR/inventory playbooks/run-functest.yml"
+ssh -F $HOME/.ssh/${DISTRO}-xci-vm-config ${DISTRO}_xci_vm "cd releng-xci/xci && PATH=/home/devuser/.local/bin:$PATH ansible-playbook -i installer/osa/files/$XCI_FLAVOR/inventory playbooks/prepare-functest.yml"
+echo "Running functest"
+ssh -F $HOME/.ssh/${DISTRO}-xci-vm-config ${DISTRO}_xci_vm_opnfv "/root/run-functest.sh"
index 59205e2..764857b 100755 (executable)
@@ -58,7 +58,7 @@ fi
 git clone https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $WORK_DIRECTORY/$GERRIT_PROJECT
 cd $WORK_DIRECTORY/$GERRIT_PROJECT
 git fetch https://gerrit.opnfv.org/gerrit/$GERRIT_PROJECT $GERRIT_REFSPEC && git checkout FETCH_HEAD
-DEPLOY_SCENARIO=$(git diff HEAD^..HEAD --name-only | grep scenarios | sed -r 's/scenarios\/(.*?)\/.*/\1/' | uniq)
+DEPLOY_SCENARIO=$(git diff HEAD^..HEAD --name-only | grep scenarios | awk -F '[/|/]' '{print $2}' | uniq)
 
 # ensure single scenario is impacted
 if [[ $(echo $DEPLOY_SCENARIO | wc -w) != 1 ]]; then
index cb75b51..0628829 100755 (executable)
@@ -39,4 +39,4 @@ if ! sed -n "/^- scenario: $DEPLOY_SCENARIO$/,/^$/p" $OPNFV_SCENARIO_REQUIREMENT
     exit 0
 fi
 
-ssh -F $HOME/.ssh/xci-vm-config ${DISTRO}_xci_vm "cd releng-xci && ./xci_test.sh"
+ssh -F $HOME/.ssh/${DISTRO}-xci-vm-config ${DISTRO}_xci_vm "cd releng-xci && ./xci_test.sh"
index 481af2a..20890fa 100644 (file)
           <<: *euphrates
       # daisy CI PODs
       - baremetal:
-          slave-label: zte-pod3
+          slave-label: daisy-baremetal
           installer: daisy
           auto-trigger-name: 'daily-trigger-disabled'
           <<: *master
index e2fee29..c036663 100644 (file)
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running unit tests in Python 2.7 ..."
           cd $WORKSPACE
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running unit tests in Python 3 ..."
           cd $WORKSPACE
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running functional tests in Python 2.7 ..."
           cd $WORKSPACE
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running functional tests in Python 3 ..."
           cd $WORKSPACE
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running coverage tests ..."
           cd $WORKSPACE
           set -o errexit
           set -o pipefail
 
+          sudo apt-get -y autoremove
           sudo apt-get install -y build-essential python-dev python3-dev
+          sudo apt-get -y clean && sudo apt-get -y autoremove
 
           echo "Running style guidelines (PEP8) tests ..."
           cd $WORKSPACE
index f82fa54..32c07f8 100755 (executable)
@@ -52,12 +52,14 @@ else
     touch $dest_path || error "Cannot create the file specified. Check that the path is correct and run the script again."
 fi
 
-info "Fetching admin.conf file..."
 if [ "$installer_type" == "compass" ]; then
+    info "Fetching admin.conf file on Compass"
     sudo docker cp compass-tasks:/opt/admin.conf $dest_path &> /dev/null
     sudo chown $(whoami):$(whoami) $dest_path
     info "Fetch admin.conf successfully"
+elif [ "$installer_type" == "joid" ]; then
+    info "Do nothing, config file has been provided in $HOME/joid_config/config for joid"
 else
-    error "Installer $installer is not supported by this script"
+    error "Installer $installer_type is not supported by this script"
 fi