Merge "Create jenkins pipeline for k6 performance tests" master
authorAndrew Fenner <Andrew.Fenner@est.tech>
Tue, 14 May 2024 09:55:39 +0000 (09:55 +0000)
committerNordix Gerrit <gerrit@nordix.org>
Tue, 14 May 2024 09:55:39 +0000 (09:55 +0000)
26 files changed:
jjb/metal3/baremetal-operator/jjb-bmo-e2e.yaml
jjb/metal3/defaults.yml
jjb/metal3/job_capm3_e2e_basic_tests.yml
jjb/metal3/job_capm3_e2e_clusterctl_upgrade_tests_prow.yml
jjb/metal3/job_capm3_e2e_feature_tests_prow.yml
jjb/metal3/job_capm3_e2e_integration_tests_prow.yml
jjb/metal3/job_capm3_e2e_k8s_upgrade_tests_prow.yml
jjb/metal3/job_capm3_periodic_e2e_clusterctl_upgrade_tests_prow.yml
jjb/metal3/job_capm3_periodic_e2e_ephemeral_tests.yml
jjb/metal3/job_capm3_periodic_e2e_feature_tests _prow.yml
jjb/metal3/job_capm3_periodic_e2e_integration_tests_prow.yml
jjb/metal3/job_capm3_periodic_e2e_k8s_upgrade_tests_prow.yml
jjb/metal3/job_capm3_periodic_integration_tests.yml [deleted file]
jjb/metal3/job_ci_image_building.yml
jjb/metal3/job_dev_env_integration_tests_prow.yml
jjb/metal3/job_dev_env_periodic_integration_tests_prow.yaml
jjb/metal3/job_integration_tests.yml [deleted file]
jjb/metal3/job_metal3_dev_tools_integration_test.yml [deleted file]
jjb/metal3/job_node_image_building.yml [moved from jjb/metal3/job_openstack_node_image_building.yml with 79% similarity]
jjb/metal3/job_openstack_image_building.yml [deleted file]
jjb/metal3/projects.yml
jjb/onap/cps/cps-performance-test-jobs.yaml
jjb/onap/cps/k6-performance-tests-trigger.sh [new file with mode: 0755]
jjb/onap/cps/prepare-performance-tests-data.sh
jjb/onap/global-templates-onap-java.yaml
jjb/onap/policy-docker-csit-jobs.sh

index 02b203cf16c1baf16f84d417df932efa4fcd659d..101cb76dfaf571471c2826ea076828db8a75fc59 100644 (file)
@@ -4,6 +4,8 @@
     # and the default GINKGO_FOCUS is empty (all tests required in BMO PRs)
     type: pull
     GINKGO_FOCUS: " "
+    # Default BMO branch to trigger the test in is "main"
+    BRANCH_NAME: "main"
     # These jobs are triggered by prow for PRs (empty trigger here) or by timer (see below)
     triggers: []
 
         # Run at 03:45 (UTC) every day
         - timed: "45 3 * * *"
 
+    # Pediodic jobs for release branches
+    - "{job_prefix}-{name}-e2e-test-{type}":
+        type: periodic-release-0.6
+        BRANCH_NAME: "release-0.6"
+        triggers:
+        # Run at 01:45 (UTC) every odd day
+        - timed: "45 1 1-31/2 * *"
+    - "{job_prefix}-{name}-e2e-test-{type}":
+        type: periodic-release-0.5
+        BRANCH_NAME: "release-0.5"
+        triggers:
+        # Run at 01:45 (UTC) every even day
+        - timed: "45 1 2-30/2 * *"
+
 - job-template:
     name: "{job_prefix}-{name}-e2e-test-{type}"
     project-type: pipeline
         description: 'Project github repo name'
     - string:
         name: PULL_BASE_REF
-        default: 'main'
+        default: '{BRANCH_NAME}'
         description: 'Ref name of the base branch'
     - string:
         name: PULL_PULL_SHA
+        default: '{BRANCH_NAME}' # Default set to branch name. This is needed when running periodic jobs
         description: 'Pull request head SHA'
     # End of Prow parameters
     - string:
index f24c7f89cdb3a9728c257e01fa26631ba8a7e61c..96cd585720ecfd8cd58472f94e718f45cb229b52 100644 (file)
     - metal3-io
     - nordix-metal3
     ci_github_repo: 'https://github.com/metal3-io/project-infra.git'
+    ci_github_jenkins_credentials_id: 'metal3-jenkins-github-username-token'
     ci_github_pipeline: 'jenkins/jobs/integration_tests.pipeline'
     e2e_feature_test_parallel_pipeline: 'jenkins/jobs/parallel_e2e_features_test.pipeline'
-    e2e_feature_test_pipeline: 'jenkins/jobs/capm3-e2e-tests.pipeline'
-    ci_github_jenkins_credentials_id: 'metal3-jenkins-github-username-token'
+    e2e_tests_pipeline: 'jenkins/jobs/capm3-e2e-tests.pipeline'
     dev_env_integration_test_pipeline: 'jenkins/jobs/dev_env_integration_tests.pipeline'
+    image_building_pipeline: 'jenkins/jobs/image_building.pipeline'
     # NOTE: auth-id is taken from Jenkins Global Configuration (NOT THE CREDENTIAL STORE!)
     # by clicking Auth ID button for the desired GitHub Server API URL
     # Please ensure you are looking at GitHub Pull Request Builder part
index 0be105003373ad320f5729f6e17ecd1b2de27c5b..eb21a4c2bb3fed8991b35eee060db72b3a2a28bc 100644 (file)
@@ -83,9 +83,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 2
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "basic"
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "jenkins/jobs/prow_integration_tests.pipeline"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
 
 - project:
index d5352105be8461e783086f014470946bcefa4d74..f35debc6855ecc5ef07dd3696e6f911252190124 100644 (file)
         name: IMAGE_OS
         default: "ubuntu"
         description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
+    - string:
+        name: CAPI_VERSION
+        default: 'v1beta1'
+        description: 'Cluster API version. E.g. v1beta1.'
+    - string:
+        name: CAPM3_VERSION
+        default: 'v1beta1'
+        description: 'Cluster API provider Metal3 version. E.g. v1beta1.'
     - string:
         name: capm3_release_branch
         default: '{capm3_release_branch}'
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 5
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "clusterctl-upgrade"
         description: 'Select the e2e upgrade test'
+
     properties:
     - build-discarder:
         days-to-keep: 30
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "{e2e_feature_test_pipeline}"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index 43c49bb6d0a8f079d81a2906ebd91f687f510a50..963835d44cfdc4968577816c8c59051a7d5c7b25 100644 (file)
@@ -85,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 4
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "features"
index 6b6f93272c6770a5f1cf3ad3422da1a389dccd4e..4e039ae83def0375c7a9f3d62ab9c0e4774415fa 100644 (file)
@@ -85,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 2
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "integration"
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "jenkins/jobs/prow_integration_tests.pipeline"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index 7b53f1e80a7d606abaab189fad5e7cb4d53d4bb6..e901daab882a97bbc63c8af6713e75a908b6343e 100644 (file)
@@ -27,7 +27,7 @@
 - job-template:
     id: capm3_e2e_k8s_upgrade_tests_prow
     name: '{job_prefix}-e2e-{k8s_versions}-upgrade-test-{capm3_target_branch}'
-    description: "CAPM3 e2e k8s upgrade tests for on {image_os}."
+    description: "CAPM3 e2e k8s upgrade tests for on ubuntu."
     project-type: pipeline
     defaults: global
     disabled: False
@@ -62,7 +62,7 @@
     # End of Prow parameters
     - string:
         name: IMAGE_OS
-        default: '{image_os}'
+        default: "ubuntu"
         description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
     - string:
         name: capm3_release_branch
@@ -85,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 4
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "k8s-upgrade"
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "jenkins/jobs/prow_integration_tests.pipeline"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index e351b155fef9517f736d48b8e3a8d3ee8c5ba4a4..ad874a19d7ad49792e8c7acddc5912fc575b3e51 100644 (file)
         name: IMAGE_OS
         default: "ubuntu"
         description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
+    - string:
+        name: CAPI_VERSION
+        default: 'v1beta1'
+        description: 'Cluster API version. E.g. v1beta1.'
+    - string:
+        name: CAPM3_VERSION
+        default: 'v1beta1'
+        description: 'Cluster API provider Metal3 version. E.g. v1beta1.'
     - string:
         name: capm3_release_branch
         default: '{capm3_release_branch}'
@@ -77,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 5
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "clusterctl-upgrade"
         artifact-num-to-keep: -1
 
     triggers:
-      - timed: "H 1 * * *"
+      - timed: '{schedule}'
 
     pipeline-scm:
       scm:
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "{e2e_feature_test_pipeline}"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index 632883ec66308d9f071b410c99b593c1f0490b4b..58b4d9d806635149784350ff0ba3dea20ceba0a3 100644 (file)
 
 - job-template:
     id: capm3_periodic_e2e_ephemeral_tests
-    name: '{job_prefix}_periodic_e2e_ephemeral_test_{image_os}'
-    description: "CAPM3 v1beta1 e2e tests in ephemeral cluster for {repo[org]}/{repo[name]} on centos."
+    name: '{job_prefix}-periodic-{image_os}-e2e-ephemeral-test-{capm3_target_branch}'
+    description: "CAPM3 v1beta1 e2e tests in ephemeral cluster on centos."
     project-type: pipeline
     defaults: global
     disabled: False
     concurrent: True
     parameters:
+    # Parameters set by Prow
     - string:
-        name: PROJECT_REPO_ORG
-        default: '{repo[org]}'
+        name: BUILD_ID
+        description: 'Used by Prow when triggering jobs'
+    - string:
+        name: PROW_JOB_ID
+        description: 'Used by Prow when triggering jobs'
+    - string:
+        name: REPO_OWNER
+        default: 'metal3-io'
         description: 'Project github repo org name'
     - string:
-        name: PROJECT_REPO_NAME
-        default: '{repo[name]}'
+        name: REPO_NAME
+        default: 'cluster-api-provider-metal3'
         description: 'Project github repo name'
     - string:
-        name: ghprbActualCommit
-        default: 'main'
-        description: 'CI Repo branch for triggering manual build'
+        name: PULL_BASE_REF
+        default: '{capm3_release_branch}'
+        description: 'Ref name of the base branch'
     - string:
-        name: ghprbAuthorRepoGitUrl
-        default: 'https://github.com/{repo[org]}/{repo[name]}.git'
-        description: 'CI Repo URL for triggering manual build'
+        name: PULL_PULL_SHA
+        default: '{capm3_release_branch}'
+        description: 'Pull request head SHA'
     - string:
-        name: ghprbTargetBranch
-        default: 'main'
-        description: 'Target branch of the PR'
+        name: PULL_NUMBER
+        description: 'Pull request number'
+    # End of Prow parameters
     - string:
         name: IMAGE_OS
         default: '{image_os}'
         description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
     - string:
         name: capm3_release_branch
-        default: 'main'
+        default: '{capm3_release_branch}'
         description: 'The target branch of CAPM3 to be used for this test'
     - string:
         name: bmo_release_branch
-        default: 'main'
+        default: '{bmo_release_branch}'
         description: 'The target branch of BMO to be used for this test'
     - string:
         name: CAPI_VERSION
-        default: 'v1beta1'
-        description: 'Cluster API version. E.g. v1beta1.'
+        default: '{capi_version}'
+        description: 'Cluster API version.'
     - string:
         name: CAPM3_VERSION
-        default: 'v1beta1'
-        description: 'Cluster API provider Metal3 version. E.g. v1beta1.'
+        default: '{capm3_version}'
+        description: 'Cluster API provider Metal3 version.'
     - string:
         name: TARGET_NODE_MEMORY
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 4
+        description: 'Number of libvirt VMs.'
     - bool:
         name: EPHEMERAL_TEST
         default: True
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "{ci_github_pipeline}"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index 35ec7722863078267f0ab1a0e1fb7ec42d1e54c5..a7c3eac135d38870c44566ae6a5dc26424771ec3 100644 (file)
         name: NUM_NODES
         default: 4
         description: 'Number of libvirt VMs.'
-    - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
     - string:
         name: GINKGO_FOCUS
         default: "features"
index d133633700017a70770536b4f984470748d45c97..ef01fe4426964edb50a9cb4ef8a8a95e0bb03281 100644 (file)
@@ -85,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 2
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "integration"
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "jenkins/jobs/prow_integration_tests.pipeline"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
index 02b2531ed3aed59eac0e29a9b771e393e4e31ac7..d49d5acf5e72658e9266ddb417212a9381a2ee51 100644 (file)
@@ -62,8 +62,8 @@
     # End of Prow parameters
     - string:
         name: IMAGE_OS
-        default: '{image_os}'
-        description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
+        default: "ubuntu"
+        description: 'Distribution to use for the target host as well as source and target cluster. Default is ubuntu'
     - string:
         name: capm3_release_branch
         default: '{capm3_release_branch}'
@@ -85,9 +85,9 @@
         default: 4096
         description: 'RAM size of the target host.'
     - string:
-        name: TESTS_FOR
-        default: "e2e_tests"
-        description: 'Tests using the e2e framework.'
+        name: NUM_NODES
+        default: 4
+        description: 'Number of libvirt VMs.'
     - string:
         name: GINKGO_FOCUS
         default: "k8s-upgrade"
         artifact-num-to-keep: -1
 
     triggers:
-      - timed: "H 18 * * *"
+      - timed: "{schedule}"
 
     pipeline-scm:
       scm:
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: "jenkins/jobs/prow_integration_tests.pipeline"
+      script-path: "{e2e_tests_pipeline}"
       lightweight-checkout: False
diff --git a/jjb/metal3/job_capm3_periodic_integration_tests.yml b/jjb/metal3/job_capm3_periodic_integration_tests.yml
deleted file mode 100644 (file)
index b7f1ebe..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
----
-#
-# ============LICENSE_START=======================================================
-#  Copyright (C) 2019 Nordix Foundation.
-# ================================================================================
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# SPDX-License-Identifier: Apache-2.0
-# ============LICENSE_END=========================================================
-
-# Description:
-# ============
-# This file contains job template definition for Cluster API Provider Metal3 (CAPM3) main integration tests.
-# This job can be triggered manually or through a Github pull request. It creates a
-# pipeline job. The pipeline scripts are maintained in Metal3 CI project infra repository.
-
-- job-template:
-    id: capm3_periodic_integration_tests
-    name: '{job_prefix}_periodic_{capm3_target_branch}_integration_test_{image_os}'
-    description: "CAPM3 {capm3_version} integration tests for {org}/{repo} on {image_os}."
-    project-type: pipeline
-    defaults: global
-    disabled: False
-    concurrent: True
-    parameters:
-    - string:
-        name: PROJECT_REPO_ORG
-        default: '{org}'
-        description: 'Project github repo org name'
-    - string:
-        name: PROJECT_REPO_NAME
-        default: '{repo}'
-        description: 'Project github repo name'
-    - string:
-        name: ghprbActualCommit
-        default: 'main'
-        description: 'CI Repo branch for triggering manual build'
-    - string:
-        name: ghprbAuthorRepoGitUrl
-        default: 'https://github.com/{org}/{repo}.git'
-        description: 'CI Repo URL for triggering manual build'
-    - string:
-        name: ghprbTargetBranch
-        default: 'main'
-        description: 'Target branch of the PR'
-    - string:
-        name: IMAGE_OS
-        default: '{image_os}'
-        description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
-    - string:
-        name: capm3_release_branch
-        default: '{capm3_release_branch}'
-        description: 'The target branch of CAPM3 to be used for this test'
-    - string:
-        name: bmo_release_branch
-        default: '{bmo_release_branch}'
-        description: 'The target branch of BMO to be used for this test'
-    - string:
-        name: CAPI_VERSION
-        default: '{capi_version}'
-        description: 'Cluster API version.'
-    - string:
-        name: CAPM3_VERSION
-        default: '{capm3_version}'
-        description: 'Cluster API provider Metal3 version.'
-    - string:
-        name: TARGET_NODE_MEMORY
-        default: 4096
-        description: 'RAM size of the target host.'
-
-    properties:
-    - build-discarder:
-        days-to-keep: 30
-        num-to-keep: 300
-        artifact-days-to-keep: -1
-        artifact-num-to-keep: -1
-
-    triggers:
-      - timed: "{schedule}"
-
-    pipeline-scm:
-      scm:
-      - git:
-          url: "{ci_github_repo}"
-          credentials-id: "{ci_github_jenkins_credentials_id}"
-          branches:
-            - '{branch|main}'
-          name: 'origin'
-          refspec: '+refs/heads/*:refs/remotes/origin/*'
-          wipe-workspace: True
-          honor-refspec: True
-          shallow-clone: False
-      script-path: "{ci_github_pipeline}"
-      lightweight-checkout: False
index 5b1107bf3b0f669e8587c45942736cf1ec3e2ca0..a036f9445d5420cf582ba262c120f88ca3aae43f 100644 (file)
 
 - job-template:
     id: ci_image_building
-    name: '{job_prefix}_ci_image_building'
+    name: '{job_prefix}_periodic_ci_image_building'
     description: "Builder job for CI images for Metal3 CI"
     project-type: pipeline
     defaults: global
     disabled: False
     concurrent: True
+    parameters:
+    - string:
+        name: IMAGE_TYPE
+        default: 'ci'
+        description: 'Specifies the type of image being built in pipeline' 
 
     properties:
     - build-discarder:
@@ -41,7 +46,7 @@
         artifact-num-to-keep: -1
 
     triggers:
-    - timed: "0 5 */5 * *"
+    - timed: "0 6 */14 * *"
 
     pipeline-scm:
       scm:
@@ -55,5 +60,5 @@
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-      script-path: 'jenkins/jobs/{id}.pipeline'
+      script-path: "{image_building_pipeline}"
       lightweight-checkout: False
index 323edd9c401aed78655c6671207f835b0f95e204..52e3393fe8edd6423413838525b94f112043f2fb 100644 (file)
@@ -26,7 +26,7 @@
 
 - job-template:
     id: dev_env_integration_tests_prow
-    name: 'dev-env-integration-test-{image_os}-{capm3_target_branch}{name_postfix}'
+    name: '{job_prefix}-dev-env-integration-test-{image_os}-{capm3_target_branch}{name_postfix}'
     description: "CAPM3 {capm3_version} integration tests on {image_os} with ironic installed from {ironic_install_type}."
     project-type: pipeline
     defaults: integration-default-values
         description: 'Project github repo name'
     - string:
         name: PULL_BASE_REF
-        default: '{capm3_release_branch}'
+        default: "main"
         description: 'Ref name of the base branch'
     - string:
         name: PULL_PULL_SHA
-        default: '{capm3_release_branch}'
+        default: "main"
         description: 'Pull request head SHA'
     - string:
         name: PULL_NUMBER
index 568bc949c185b54845c2fa7f6ee68cbe1cf3f85f..fe02c46d4a5eb096ae7ad31aeedb937df49e4117 100644 (file)
@@ -26,7 +26,7 @@
 
 - job-template:
     id: dev_env_periodic_integration_tests_prow
-    name: 'dev-env-periodic-integration-test-{image_os}-{capm3_target_branch}{name_postfix}'
+    name: '{job_prefix}-periodic-dev-env-integration-test-{image_os}-{capm3_target_branch}{name_postfix}'
     description: "CAPM3 {capm3_version} integration tests on {image_os} with ironic installed from {ironic_install_type}."
     project-type: pipeline
     defaults: integration-default-values
         description: 'Project github repo name'
     - string:
         name: PULL_BASE_REF
-        default: '{capm3_release_branch}'
+        default: "main"
         description: 'Ref name of the base branch'
     - string:
         name: PULL_PULL_SHA
-        default: '{capm3_release_branch}'
+        default: "main"
         description: 'Pull request head SHA'
     - string:
         name: PULL_NUMBER
diff --git a/jjb/metal3/job_integration_tests.yml b/jjb/metal3/job_integration_tests.yml
deleted file mode 100644 (file)
index 030d4c4..0000000
+++ /dev/null
@@ -1,133 +0,0 @@
----
-#
-# ============LICENSE_START=======================================================
-#  Copyright (C) 2019 Nordix Foundation.
-# ================================================================================
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# SPDX-License-Identifier: Apache-2.0
-# ============LICENSE_END=========================================================
-
-# Description:
-# ============
-# This file contains job template definition for Cluster API Provider Metal3 (CAPM3) integration tests.
-# This job can be triggered manually or through a Github pull request. It creates a
-# pipeline job. The pipeline scripts are maintained in Metal3 CI project infra repository.
-
-- job-template:
-    name: '{job_prefix}_{proj}_{capm3_target_branch}_integration_test_{image_os}{name_postfix}'
-    description: "CAPM3 {capm3_version} integration tests for {org}/{repo} on {image_os} with ironic installed from {ironic_install_type}."
-    id: 'integration_tests'
-    project-type: pipeline
-    defaults: integration-default-values
-    disabled: False
-    concurrent: True
-    parameters:
-    - string:
-        name: PROJECT_REPO_ORG
-        default: '{org}'
-        description: 'Project github repo org name'
-    - string:
-        name: PROJECT_REPO_NAME
-        default: '{repo}'
-        description: 'Project github repo name'
-    - string:
-        name: ghprbActualCommit
-        default: 'main'
-        description: 'CI Repo branch for triggering manual build'
-    - string:
-        name: ghprbAuthorRepoGitUrl
-        default: 'https://github.com/{org}/{repo}.git'
-        description: 'CI Repo URL for triggering manual build'
-    - string:
-        name: ghprbTargetBranch
-        default: 'main'
-        description: 'Target branch of the PR'
-    - string:
-        name: capm3_release_branch
-        default: '{capm3_release_branch}'
-        description: 'The target branch of CAPM3 to be used for this test'
-    - string:
-        name: bmo_release_branch
-        default: '{bmo_release_branch}'
-        description: 'The target branch of BMO to be used for this test'
-    - string:
-        name: IMAGE_OS
-        default: '{image_os}'
-        description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
-    - string:
-        name: CAPI_VERSION
-        default: '{capi_version}'
-        description: 'Cluster API version.'
-    - string:
-        name: CAPM3_VERSION
-        default: '{capm3_version}'
-        description: 'Cluster API provider Metal3 version.'
-    - string:
-        name: TARGET_NODE_MEMORY
-        default: 4096
-        description: 'RAM size of the target host.'
-    - string:
-        name: IRONIC_INSTALL_TYPE
-        default: '{ironic_install_type}'
-        description: 'Sets the installation type of ironic during ironic-image build of the BMO deployment'
-    - string:
-        name: IRONIC_USE_MARIADB
-        default: '{ironic_use_mariadb}'
-        description: 'If Ironic should use MariaDB or not.'
-    - string:
-        name: BUILD_MARIADB_IMAGE_LOCALLY
-        default: '{build_mariadb_image_locally}'
-    properties:
-    - build-discarder:
-        days-to-keep: 30
-        num-to-keep: 300
-        artifact-days-to-keep: -1
-        artifact-num-to-keep: -1
-    - github:
-        url: https://github.com/{org}/{repo}
-
-    triggers:
-    - github-pull-request:
-        admin-list:
-        - '{ci_github_admin_user}'
-        org-list: "{ci_github_whitelist_org}"
-        cron: 'H/5 * * * *'
-        auth-id: "{ci_ghprb_auth_id}"
-        trigger-phrase: '.*?/test-{image_os}-integration-{capm3_target_branch}{trigger_postfix}.*?'
-        skip-build-phrase: '/skip-test'
-        only-trigger-phrase: True
-        github-hooks: True
-        permit-all: False
-        auto-close-on-fail: False
-        allow-whitelist-orgs-as-admins: True
-        white-list-target-branches: "{target_branches}"
-        status-context: "test-{image_os}-integration-{capm3_target_branch}"
-        success-status: "Passed"
-        failure-status: "Failed"
-        error-status: "Error"
-        cancel-builds-on-update: True
-    pipeline-scm:
-      scm:
-      - git:
-          url: "{ci_github_repo}"
-          credentials-id: "{ci_github_jenkins_credentials_id}"
-          branches:
-          - '{branch|main}'
-          name: 'origin'
-          refspec: '+refs/heads/*:refs/remotes/origin/*'
-          wipe-workspace: True
-          honor-refspec: True
-          shallow-clone: False
-      script-path: "{ci_github_pipeline}"
-      lightweight-checkout: False
diff --git a/jjb/metal3/job_metal3_dev_tools_integration_test.yml b/jjb/metal3/job_metal3_dev_tools_integration_test.yml
deleted file mode 100644 (file)
index 031698a..0000000
+++ /dev/null
@@ -1,121 +0,0 @@
----
-#
-# ============LICENSE_START=======================================================
-#  Copyright (C) 2019 Nordix Foundation.
-# ================================================================================
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# SPDX-License-Identifier: Apache-2.0
-# ============LICENSE_END=========================================================
-
-# Description:
-# ============
-# This file contains job template definition for Cluster API Provider Metal3 (CAPM3)
-# dev tools integration tests.
-# This job can be triggered manually or through a Github pull request. It creates a
-# pipeline job. The pipeline scripts are maintained in Nordix/metal3-dev-tools repository.
-
-- job-template:
-    id: metal3_dev_tools_integration_test
-    name: 'metal3_dev_tools_integration_test_{image_os}'
-    description: "CAPM3 v1beta1 metal3-dev-tools integration tests for {repo[org]}/{repo[name]} on {image_os}."
-    project-type: pipeline
-    defaults: global
-    disabled: False
-    concurrent: True
-    parameters:
-    - string:
-        name: PROJECT_REPO_ORG
-        default: '{repo[org]}'
-        description: 'Project github repo org name'
-    - string:
-        name: PROJECT_REPO_NAME
-        default: '{repo[name]}'
-        description: 'Project github repo name'
-    - string:
-        name: ghprbActualCommit
-        default: 'main'
-        description: 'CI Repo branch for triggering manual build'
-    - string:
-        name: ghprbAuthorRepoGitUrl
-        default: 'https://github.com/{repo[org]}/{repo[name]}.git'
-        description: 'CI Repo URL for triggering manual build'
-    - string:
-        name: ghprbTargetBranch
-        default: 'main'
-        description: 'Target branch of the PR'
-    - string:
-        name: IMAGE_OS
-        default: '{image_os}'
-        description: 'Distribution to use for the target host as well as source and target cluster. Can be ubuntu or centos'
-    - string:
-        name: CAPI_VERSION
-        default: 'v1beta1'
-        description: 'Cluster API version. E.g. v1beta1.'
-    - string:
-        name: CAPM3_VERSION
-        default: 'v1beta1'
-        description: 'Cluster API provider Metal3 version. E.g. v1beta1.'
-    - string:
-        name: TARGET_NODE_MEMORY
-        default: 4096
-        description: 'RAM size of the target host.'
-    - string:
-        name: KUBERNETES_VERSION
-        default: ""
-        description: 'Kubernetes version'
-
-    properties:
-    - build-discarder:
-        days-to-keep: 30
-        num-to-keep: 300
-        artifact-days-to-keep: -1
-        artifact-num-to-keep: -1
-    - github:
-        url: https://github.com/{repo[org]}/{repo[name]}
-
-    triggers:
-    - github-pull-request:
-        admin-list:
-          - '{ci_github_admin_user}'
-        org-list: "{ci_github_whitelist_org}"
-        cron: 'H/5 * * * *'
-        auth-id: "{ci_ghprb_auth_id}"
-        trigger-phrase: '.*?/test-integration-metal3-dev-tools-{image_os}.*?'
-        skip-build-phrase: '/skip-test'
-        only-trigger-phrase: True
-        github-hooks: True
-        permit-all: False
-        auto-close-on-fail: False
-        allow-whitelist-orgs-as-admins: True
-        white-list-target-branches:
-          - 'main'
-        status-context: "test-integration-metal3-dev-tools-{image_os}"
-        success-status: "Passed"
-        failure-status: "Failed"
-        error-status: "Error"
-        cancel-builds-on-update: True
-    pipeline-scm:
-      scm:
-      - git:
-          url: "{ci_github_repo}"
-          credentials-id: "{ci_github_jenkins_credentials_id}"
-          branches:
-            - '{branch|main}'
-          name: 'origin'
-          refspec: '+refs/heads/*:refs/remotes/origin/*'
-          wipe-workspace: True
-          honor-refspec: True
-          shallow-clone: False
-      script-path: 'ci/jobs/metal3_dev_tools_integration_tests.pipeline'
-      lightweight-checkout: False
similarity index 79%
rename from jjb/metal3/job_openstack_node_image_building.yml
rename to jjb/metal3/job_node_image_building.yml
index f12d718148b3402a4b75441b660df47727063e8b..45388232483e056e4ff567c62df26263171ab351 100644 (file)
@@ -1,4 +1,3 @@
----
 #
 # ============LICENSE_START=======================================================
 #  Copyright (C) 2019 Nordix Foundation.
 # NOTE: KUBERNETES_VERSION and KUBECTL_SHA256 are changed as a pair
 
 - job-template:
-    id: openstack_node_image_building
-    name: '{job_prefix}_openstack_node_image_building'
-    description: "Builder job for Openstack node images for Metal3 CI"
+    id: node_image_building
+    name: '{job_prefix}_periodic_node_image_building'
+    description: "Builder job for node images for Metal3 CI"
     project-type: pipeline
     defaults: global
     disabled: False
     concurrent: True
     parameters:
+    - string:
+        name: IMAGE_TYPE
+        default: 'node'
+        description: 'Specifies the type of image being built in pipeline'
     - string:
         name: KUBERNETES_VERSION
-        default: "v1.29.0"
+        default: "v1.30.0"
         description: 'Kubernetes version'
     - string:
         name: KUBECTL_SHA256
-        default: '0e03ab096163f61ab610b33f37f55709d3af8e16e4dcc1eb682882ef80f96fd5'  # v1.29.0
+        default: '7c3807c0f5c1b30110a2ff1e55da1d112a6d0096201f1beb81b269f582b5d1c5' # v1.30.0
         description: 'Kubectl SHA256 digest matching KUBERNETES_VERSION'
     - string:
         name: CRICTL_VERSION
-        default: "v1.29.0"
+        default: "v1.30.0"
         description: 'CRICTL VERSION'
     - string:
         name: CRIO_VERSION
-        default: "v1.29.0"
+        default: "v1.29.3"
         description: 'CRI-O VERSION'
 
     properties:
         artifact-days-to-keep: -1
         artifact-num-to-keep: -1
 
+    triggers:
+    - timed: "0 5 */14 * *"
+
     pipeline-scm:
       scm:
       - git:
           url: "{ci_github_repo}"
           credentials-id: "{ci_github_jenkins_credentials_id}"
           branches:
-            - 'main'
+          - 'main'
           name: 'origin'
           refspec: '+refs/heads/*:refs/remotes/origin/*'
           wipe-workspace: True
           honor-refspec: True
           shallow-clone: False
-          included-regions:
-                - "ci/images/.*"
-                - "ci/scripts/image_scripts/.*"
-      script-path: 'ci/jobs/{id}.pipeline'
+      script-path: "{image_building_pipeline}"
       lightweight-checkout: False
diff --git a/jjb/metal3/job_openstack_image_building.yml b/jjb/metal3/job_openstack_image_building.yml
deleted file mode 100644 (file)
index 7cad3c2..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
----
-#
-# ============LICENSE_START=======================================================
-#  Copyright (C) 2019 Nordix Foundation.
-# ================================================================================
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# SPDX-License-Identifier: Apache-2.0
-# ============LICENSE_END=========================================================
-
-# Description:
-# ============
-# This file contains job template definition for Openstack image building tests.
-# This job can be triggered manually or through a Github pull request. It creates a
-# pipeline job. The pipeline scripts are maintained in Nordix/metal3-dev-tools repository.
-
-# NOTE: KUBERNETES_VERSION and KUBECTL_SHA256 are changed as a pair
-
-- job-template:
-    id: openstack_image_building
-    name: '{job_prefix}_openstack_image_building'
-    description: "Builder job for Openstack images for Metal3 CI"
-    project-type: pipeline
-    defaults: global
-    disabled: False
-    concurrent: True
-    parameters:
-    - string:
-        name: KUBERNETES_VERSION
-        default: "v1.29.0"
-        description: 'Kubernetes version'
-    - string:
-        name: KUBECTL_SHA256
-        default: '0e03ab096163f61ab610b33f37f55709d3af8e16e4dcc1eb682882ef80f96fd5'  # v1.29.0
-        description: 'Kubectl SHA256 digest matching KUBERNETES_VERSION'
-    - string:
-        name: KIND_NODE_IMAGE_VERSION
-        default: "v1.29.0"
-        description: 'Kind node container image version'
-
-    properties:
-    - build-discarder:
-        days-to-keep: 30
-        num-to-keep: 300
-        artifact-days-to-keep: -1
-        artifact-num-to-keep: -1
-
-    pipeline-scm:
-      scm:
-      - git:
-          url: "{ci_github_repo}"
-          credentials-id: "{ci_github_jenkins_credentials_id}"
-          branches:
-            - 'main'
-          name: 'origin'
-          refspec: '+refs/heads/*:refs/remotes/origin/*'
-          wipe-workspace: True
-          honor-refspec: True
-          shallow-clone: False
-      script-path: 'ci/jobs/{id}.pipeline'
-      lightweight-checkout: False
index 8402afacd7b0cb6af2b6df2296382c0d458236b5..eab6bdd257533c9352cc248bd7646588cdbed610 100644 (file)
     ci_github_whitelist_org:
     - nordix-metal3
     jobs:
-    - openstack_image_building
-    - openstack_node_image_building
     - docker_image_building
     - update_nordix_repos
     - periodic_fullstack_building
     - fullstack_building_test
-    - metal3_dev_tools_integration_test:
-        image_os:
-        - ubuntu
-        - centos
     - artifact_cleanup
     repo:
       org: "Nordix"
     name: 'image_building'
     jobs:
     - ci_image_building
-
-- project:
-    name: integration-tests
-    org: metal3-io
-    proj:
-    - metal3_dev_env:
-        repo: metal3-dev-env
-    - project_infra:
-        repo: project-infra
-        branch: '${{ghprbActualCommit}}'
-        ci_github_repo: '${{ghprbAuthorRepoGitUrl}}'
-    - capm3:
-        repo: cluster-api-provider-metal3
-    - bmo:
-        repo: baremetal-operator
-    - ipam:
-        repo: ip-address-manager
-    - ironic_image:
-        repo: ironic-image
-        name_postfix: '_ironic_from_source'
-        trigger_postfix: '-ironic-source'
-        ironic_install_type: 'source'
-        target_branches:
-        - 'main'
-        - 'release-23.1'
-        - 'release-24.0'
-        - 'release-24.1'
-    - ironic_image:
-        repo: ironic-image
-    - ironic_ipa_downloader:
-        repo: ironic-ipa-downloader
-    - mariadb_image:
-        repo: mariadb-image
-        build_mariadb_image_locally: 'true'
-        ironic_use_mariadb: 'true'
-    image_os:
-    - ubuntu
-    - centos
-    capm3_target_branch:
-    - main:
-        capi_version: v1beta1
-        capm3_version: v1beta1
-        capm3_release_branch: main
-        bmo_release_branch: main
-        target_branches:
-        - 'main'
-    - release-1-7:
-        capi_version: v1beta1
-        capm3_version: v1beta1
-        capm3_release_branch: release-1.7
-        bmo_release_branch: release-0.6
-        target_branches:
-        - 'main'
-        - 'release-1.7'
-        - 'release-0.6'
-    - release-1-6:
-        capi_version: v1beta1
-        capm3_version: v1beta1
-        capm3_release_branch: release-1.6
-        bmo_release_branch: release-0.5
-        target_branches:
-        - 'main'
-        - 'release-1.6'
-        - 'release-0.5'
-    - release-1-5:
-        capi_version: v1beta1
-        capm3_version: v1beta1
-        capm3_release_branch: release-1.5
-        bmo_release_branch: release-0.4
-        target_branches:
-        - 'main'
-        - 'release-1.5'
-        - 'release-0.4'
-    jobs:
-    - integration_tests
-
-- project:
-    name: metal3-dev-env-main-tests
-    org: metal3-io
-    repo: metal3-dev-env
-    image_os:
-    - ubuntu
-    - centos
-    jobs:
-    - capm3_periodic_integration_tests:
-        capm3_target_branch:
-        - main:
-            capi_version: v1beta1
-            capm3_version: v1beta1
-            capm3_release_branch: main
-            bmo_release_branch: main
-            schedule: "H 4 * * *"
-        - release-1-7:
-            capi_version: v1beta1
-            capm3_version: v1beta1
-            capm3_release_branch: release-1.7
-            bmo_release_branch: release-0.6
-            schedule: "30 4 * * *"
-        - release-1-6:
-            capi_version: v1beta1
-            capm3_version: v1beta1
-            capm3_release_branch: release-1.6
-            bmo_release_branch: release-0.5
-            schedule: "30 4 * * *"
-        - release-1-5:
-            capi_version: v1beta1
-            capm3_version: v1beta1
-            capm3_release_branch: release-1.5
-            bmo_release_branch: release-0.4
-            schedule: "30 4 * * *"
+    - node_image_building
 
 - project:
     name: bml-tests
             capm3_version: v1beta1
             capm3_release_branch: main
             bmo_release_branch: main
-            schedule: "H 2 * * *"
+            schedule: "H 22 2-30/2 * *" # Runs on even days 10 PM
         - release-1-7:
             capi_version: v1beta1
             capm3_version: v1beta1
             capm3_release_branch: release-1.7
             bmo_release_branch: release-0.6
-            schedule: "H 2 * * *"
+            schedule: "H 3 2-30/2 * *" # Runs on even days 3 AM
         - release-1-6:
             capi_version: v1beta1
             capm3_version: v1beta1
             capm3_release_branch: release-1.6
             bmo_release_branch: release-0.5
-            schedule: "H 8 * * *"
+            schedule: "H 8 2-30/2 * *" # Runs on even days 8 AM
         - release-1-5:
             capi_version: v1beta1
             capm3_version: v1beta1
             capm3_release_branch: release-1.5
             bmo_release_branch: release-0.4
-            schedule: "H 11 * * *"
+            schedule: "H 13 2-30/2 * *" # Runs on even days 1 PM
+        exclude:
+        - image_os: ubuntu # This is to disable the tests running on ubuntu, to save resources
     - capm3_e2e_clusterctl_upgrade_tests_prow:
         capm3_target_branch:
         - main:
         - image_os: centos
     - capm3_e2e_k8s_upgrade_tests_prow:
         k8s_versions:
+        - 1-29-1-30:
+            k8s_version_upgrade_from: v1.29.0
+            k8s_version_upgrade_to: v1.30.0
+            kubectl_sha256: 7c3807c0f5c1b30110a2ff1e55da1d112a6d0096201f1beb81b269f582b5d1c5 # v1.30.0
+            capm3_release_branch: main
+            bmo_release_branch: main
+            capm3_target_branch: main
         - 1-28-1-29:
             k8s_version_upgrade_from: v1.28.1
             k8s_version_upgrade_to: v1.29.0
             capm3_release_branch: main
             bmo_release_branch: main
             capm3_target_branch: main
-        - 1-26-1-27:
-            k8s_version_upgrade_from: v1.26.4
-            k8s_version_upgrade_to: v1.27.4
-            kubectl_sha256: 4685bfcf732260f72fce58379e812e091557ef1dfc1bc8084226c7891dd6028f # v1.27.4
-            capm3_release_branch: main
-            capm3_target_branch: main
-            bmo_release_branch: main
-        - 1-28-1-29:
-            k8s_version_upgrade_from: v1.28.1
-            k8s_version_upgrade_to: v1.29.0
-            kubectl_sha256: 0e03ab096163f61ab610b33f37f55709d3af8e16e4dcc1eb682882ef80f96fd5 # v1.29.0
+        - 1-29-1-30:
+            k8s_version_upgrade_from: v1.29.0
+            k8s_version_upgrade_to: v1.30.0
+            kubectl_sha256: 7c3807c0f5c1b30110a2ff1e55da1d112a6d0096201f1beb81b269f582b5d1c5 # v1.30.0
             capm3_release_branch: release-1.7
             bmo_release_branch: release-0.6
             capm3_target_branch: release-1-7
         - main:
             capm3_release_branch: main
             bmo_release_branch: main
+            schedule: "H 1 * * TUE,THU,SAT"
         - release-1-7:
             capm3_release_branch: release-1.7
             bmo_release_branch: release-0.6
+            schedule: "H 1 * * MON"
         - release-1-6:
             capm3_release_branch: release-1.6
             bmo_release_branch: release-0.5
+            schedule: "H 1 * * WED"
         - release-1-5:
             capm3_release_branch: release-1.5
             bmo_release_branch: release-0.4
+            schedule: "H 1 * * FRI"
         exclude:
         - image_os: centos
     - capm3_periodic_e2e_k8s_upgrade_tests_prow:
         k8s_versions:
+        - 1-29-1-30:
+            k8s_version_upgrade_from: v1.29.0
+            k8s_version_upgrade_to: v1.30.0
+            kubectl_sha256: 7c3807c0f5c1b30110a2ff1e55da1d112a6d0096201f1beb81b269f582b5d1c5 # v1.30.0
+            capm3_release_branch: main
+            bmo_release_branch: main
+            capm3_target_branch: main
+            schedule: "H 4 * * MON"
         - 1-28-1-29:
             k8s_version_upgrade_from: v1.28.1
             k8s_version_upgrade_to: v1.29.0
             capm3_release_branch: main
             bmo_release_branch: main
             capm3_target_branch: main
+            schedule: "H 4 * * THU"
         - 1-27-1-28:
             k8s_version_upgrade_from: v1.27.4
             k8s_version_upgrade_to: v1.28.1
             capm3_release_branch: main
             bmo_release_branch: main
             capm3_target_branch: main
-        - 1-26-1-27:
-            k8s_version_upgrade_from: v1.26.4
-            k8s_version_upgrade_to: v1.27.4
-            kubectl_sha256: 4685bfcf732260f72fce58379e812e091557ef1dfc1bc8084226c7891dd6028f # v1.27.4
-            capm3_release_branch: main
-            bmo_release_branch: main
-            capm3_target_branch: main
-        - 1-28-1-29:
-            k8s_version_upgrade_from: v1.28.1
-            k8s_version_upgrade_to: v1.29.0
-            kubectl_sha256: 0e03ab096163f61ab610b33f37f55709d3af8e16e4dcc1eb682882ef80f96fd5 # v1.29.0
+            schedule: "H 4 * * FRI"
+        - 1-29-1-30:
+            k8s_version_upgrade_from: v1.29.0
+            k8s_version_upgrade_to: v1.30.0
+            kubectl_sha256: 7c3807c0f5c1b30110a2ff1e55da1d112a6d0096201f1beb81b269f582b5d1c5 # v1.30.0
             capm3_release_branch: release-1.7
             bmo_release_branch: release-0.6
             capm3_target_branch: release-1-7
+            schedule: "H 4 * * TUE"
         - 1-28-1-29:
             k8s_version_upgrade_from: v1.28.1
             k8s_version_upgrade_to: v1.29.0
             capm3_release_branch: release-1.6
             bmo_release_branch: release-0.5
             capm3_target_branch: release-1-6
+            schedule: "H 4 * * WED"
         - 1-26-1-27:
             k8s_version_upgrade_from: v1.26.4
             k8s_version_upgrade_to: v1.27.4
             capm3_release_branch: release-1.5
             bmo_release_branch: release-0.4
             capm3_target_branch: release-1-5
+            schedule: "H 4 * * SAT"
         exclude:
         - image_os: centos
-- project:
-    name: "capm3-periodic-tests"
-    repo:
-      org: "metal3-io"
-      name: "cluster-api-provider-metal3"
-    image_os:
-    - ubuntu
-    - centos
-    jobs:
     - capm3_periodic_e2e_ephemeral_tests:
+        capm3_target_branch:
+        - main:
+            capi_version: v1beta1
+            capm3_version: v1beta1
+            capm3_release_branch: main
+            bmo_release_branch: main
         exclude:
         - image_os: ubuntu
 
             capm3_release_branch: main
             bmo_release_branch: main
             schedule: "H 4 * * *"
-        - release-1-6:
-            capi_version: v1beta1
-            capm3_version: v1beta1
-            capm3_release_branch: release-1.6
-            bmo_release_branch: release-0.5
-            schedule: "30 4 * * *"
index 01647e0c8a84fee13ad2306836a8f98a4460fe8e..6676742794896d7edc3947d8bb2d1e198bd04059 100644 (file)
     name: cps-tests-plots
     project: cps
     project-name: cps
-    timer: "15 4 * * *"
+    timer: "0 1-23/2 * * *"
 
     jobs:
-        - 'onap-{project-name}-performance-tests-plots'
\ No newline at end of file
+        - 'onap-{project-name}-performance-tests-plots'
+
+- project:
+      name: cps-k6-tests
+      project: cps
+      project-name: cps
+      timer: "15 7 * * *"
+
+      jobs:
+          - 'onap-{project-name}-performance-test-k6'
diff --git a/jjb/onap/cps/k6-performance-tests-trigger.sh b/jjb/onap/cps/k6-performance-tests-trigger.sh
new file mode 100755 (executable)
index 0000000..6377aa9
--- /dev/null
@@ -0,0 +1,57 @@
+#!/bin/bash
+#
+# Copyright 2024 Nordix Foundation.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+set -o errexit  # Exit on most errors
+set -o nounset  # Disallow expansion of unset variables
+set -o pipefail # Use last non-zero exit code in a pipeline
+set -o xtrace   # Trace logging - disabled to avoid producing gigabytes of logs
+
+#############################################################################################################################
+################################################ M A I N ####################################################################
+#############################################################################################################################
+cd "$WORKSPACE"
+
+# Check if cps repository directory exists
+if [ -d "cps" ]; then
+  # If it exists, wipe the directory
+  echo "wiping the old cps repository..."
+  rm -rf cps
+fi
+
+# Check if build-logs exists
+if [ -d "build-logs" ]; then
+  # If it exists, wipe the directory
+  echo "wiping the old build-logs directory..."
+  rm -rf "build-logs"
+fi
+
+mkdir "build-logs"
+
+# Close the cps repository
+git clone https://gerrit.nordix.org/onap/cps
+cd cps
+
+# Since the commit which includes k6 test has not been merged yet
+git fetch https://gerrit.nordix.org/onap/cps refs/changes/22/21022/10 && git checkout FETCH_HEAD
+
+working_directory=$(pwd)
+
+# Provide execute permission to runner script
+chmod 777 "$working_directory/k6-tests/run-k6-tests.sh"
+
+# Run all k6 tests and save the logs
+"$working_directory/k6-tests/run-k6-tests.sh" 2>&1 | tee "$WORKSPACE/build-logs/k6-build.log"
index 47739442a9ceeaed4c21d93c6632ce2e865beb63..276ea4735f929581686309f75cf5c191748f3fd3 100755 (executable)
@@ -24,9 +24,13 @@ set -o pipefail # Use last non-zero exit code in a pipeline
 ################################################ F U N C T I O N S ##########################################################
 #############################################################################################################################
 
-cps_test_names=("Delete data nodes for anchor" "Delete one large node" "Batch delete 100 lists elements" "Batch delete 100 containers" "Query across anchors top element" "Delete root node" "Query across anchors ancestors" "Query across anchors leaf condition + an" "Read datatrees using openroadm root" "Read datatrees using openroadm top eleme" "Query 1 anchor leaf condition + ancestor" "Query 1 anchor top element" "Creating 33,000 books" "Replace list of 0 with 100" "Query ancestors with all descendants" "Replace 0 nodes with 100" "Writing 6400 books" "Read datatrees with all descendants" "Query 1 anchor ancestors" "Writing 400 devices" "Writing 3200 books" "Saving list of 100 devices" "Saving list of 50 devices" "Saving list of 400 devices" "Query with all descendants" "Writing 100 devices" "Writing 50 devices" "Writing 200 devices" "Read datatrees for multiple xpaths" "Saving list of 200 devices")
+cps_stable_test_names=("Delete data nodes for anchor" "Delete one large node" "Batch delete 100 lists elements" "Batch delete 100 containers" "Query across anchors top element" "Delete root node" "Query across anchors ancestors" "Query across anchors leaf condition + an" "Read datatrees using openroadm root" "Read datatrees using openroadm top eleme" "Query 1 anchor leaf condition + ancestor" "Query 1 anchor top element" "Creating 33,000 books" "Replace list of 0 with 100" "Query ancestors with all descendants" "Replace 0 nodes with 100" "Writing 6400 books" "Read datatrees with all descendants" "Query 1 anchor ancestors" "Writing 400 devices" "Writing 3200 books" "Saving list of 100 devices" "Saving list of 50 devices" "Saving list of 400 devices" "Query with all descendants" "Writing 100 devices" "Writing 50 devices" "Writing 200 devices" "Read datatrees for multiple xpaths" "Saving list of 200 devices")
 
-ncmp_test_name_names=("Look up CM-handles by module-set-tag")
+ncmp_stable_test_names=("Look up CM-handles by module-set-tag" "CpsPath Registry attributes Query")
+
+cps_unstable_test_names=("Batch delete 100 non-existing"  "Batch delete 100 whole lists"  "Query with direct descendants"  "Delete 100 whole lists"  "Query 1 anchor non-existing data"  "Read datatrees with no descendants"  "Read non-existing xpaths"  "Query with no descendants"  "Update leaves for 100 data nodes"  "Query ancestors with no descendants"  "Replace 100 with new leaf values"  "Query ancestors with direct descendants"  "Replace list of 100 with new leaf values"  "Replace list of 100 using same data"  "Deleting test data"  "Replace list of 100 nodes with 1"  "Read datatrees using openroadm whole lis"  "Replace 100 using same data"  "Read datatrees with direct descendants"  "Replace 100 nodes with 0"  "Replace list with 50 existing and 50 new"  "Delete 100 lists elements"  "Replace 50 existing and 50 new"  "Writing 800 books"  "Delete 100 containers"  "Replace list with 100 new nodes"  "Replace 100 with 100 new nodes"  "Writing 1600 books"  "Saving list of 200 devices"  "Read datatrees for multiple xpaths")
+
+ncmp_unstable_test_names=("Look up CM-handle by id" "Update matching subscription" "Look up CM-handle by alternate-id")
 
 JENKINS_JOB_URL="https://jenkins.nordix.org/job/onap-cps-master-performance-test-java"
 
@@ -54,7 +58,7 @@ getLastRecordedBuildNumber() {
     local left_side=$(echo "$last_line" | cut -d ',' -f 1)
     echo "$left_side"
   else
-    echo "File '$file_name' not found in the current directory"
+    echo "0"
   fi
 }
 
@@ -75,11 +79,17 @@ getAndRecordPerformanceJobResultForBuild() {
   buildNumber="$1"
   getConsoleText "$buildNumber"
   # Loop through each text name
-  for cps_test_name in "${cps_test_names[@]}"; do
-    getAndRecordDataResults "$consoleText" "$cps_test_name" "$cps_test_name.txt" "$buildNumber"
+  for cps_stable_test_name in "${cps_stable_test_names[@]}"; do
+    getAndRecordDataResults "$consoleText" "$cps_stable_test_name" "$cps_stable_test_name.txt" "$buildNumber"
+  done
+  for ncmp_stable_test_name in "${ncmp_stable_test_names[@]}"; do
+    getAndRecordDataResults "$consoleText" "$ncmp_stable_test_name" "$ncmp_stable_test_name.txt" "$buildNumber"
   done
-  for ncmp_test_name in "${ncmp_test_name_names[@]}"; do
-    getAndRecordDataResults "$consoleText" "$ncmp_test_name" "$ncmp_test_name.txt" "$buildNumber"
+  for cps_unstable_test_name in "${cps_unstable_test_names[@]}"; do
+    getAndRecordDataResults "$consoleText" "$cps_unstable_test_name" "$cps_unstable_test_name.txt" "$buildNumber"
+  done
+  for ncmp_unstable_test_name in "${ncmp_unstable_test_names[@]}"; do
+    getAndRecordDataResults "$consoleText" "$ncmp_unstable_test_name" "$ncmp_unstable_test_name.txt" "$buildNumber"
   done
 }
 
@@ -153,59 +163,10 @@ EOT
   rm gnuplot_script.gp
 }
 
-# Builds index.html file (main page)
-buildMainPageHtmlReport() {
-cat <<EOT >"index.html"
-<!DOCTYPE html>
-<html>
-<head>
-  <title>Performance Review</title>
-</head>
-<body>
-    <h1 style="text-align: center;">Performance Review</h1>
-    <h4>Last updated for performance job build no. $latestRecordedBuild on $formattedTimestampOfLatestRecordedBuild</h4>
-    <p>The performance tests job runs every two hours, providing performance metrics. The following graphs update at 04:15 UTC.</p>
-    <p>Successful performance tests job build adds new data, but even if a build fails, existing data is retained.</p>
-    <p>Updates occur whenever new successful data is available.</p>
-
-    <table align="center">
-EOT
-
-# Loop through the test names and chart file names to generate HTML rows for CPS
-for cps_test_name in "${cps_test_names[@]}"; do
-    cat <<EOF >>index.html
-        <tr> <!-- Row for $cps_test_name -->
-            <td align="center" style="padding: 10px;">
-                <figcaption>"$cps_test_name (CPS)"</figcaption>
-                <img src="$cps_test_name.png" width="750" height="300">
-            </td>
-        </tr>
-EOF
-done
-
-# Loop through the test names and chart file names to generate HTML rows for NCMP
-for ncmp_test_name in "${ncmp_test_name_names[@]}"; do
-    cat <<EOF >>index.html
-        <tr> <!-- Row for $ncmp_test_name -->
-            <td align="center" style="padding: 10px;">
-                <figcaption>"$ncmp_test_name (NCMP)"</figcaption>
-                <img src="$ncmp_test_name.png" width="750" height="300">
-            </td>
-        </tr>
-EOF
-done
-
-# Close the HTML file
-cat <<EOT >>index.html
-    </table>
-</body>
-</html>
-EOT
-}
-
-# Builds sub-HTML pages
-buildSubPageHtmlReport() {
-  chartFileName="$1"
+# Builds category html file
+buildCategoryHtmlReport() {
+  # use indirect expansion to get all elements of the array
+  categoryName=("${!1}")
   reportTitle="$2"
   outputFile="$3"
   cat <<EOT >"$outputFile"
@@ -215,11 +176,29 @@ buildSubPageHtmlReport() {
     <title>$reportTitle</title>
     </head>
     <body>
-        <h1>$reportTitle</h1>
-        <h4>Last updated for performance job build no. $latestRecordedBuild on $formattedTimestampOfLatestRecordedBuild</h4>
-        <img src="$chartFileName" alt="Graph Image">
+      <h1 style="text-align: center;">$reportTitle</h1>
+      <h4>Last updated for performance job build no. $latestRecordedBuild on $formattedTimestampOfLatestRecordedBuild</h4>
+      <table align="center">
+EOT
+# Loop through the test names to generate HTML rows
+for test_name_in_category in "${categoryName[@]}"; do
+    cat <<EOF >>"$outputFile"
+        <tr> <!-- Row for $test_name_in_category -->
+            <td align="center" style="padding: 10px;">
+                <figcaption>"$test_name_in_category"</figcaption>
+                <img src="$test_name_in_category.png" width="750" height="300">
+            </td>
+        </tr>
+EOF
+done
+# Close the HTML file
+cat <<EOT >>"$outputFile"
+      </table>
+        <p>The performance tests job runs every two (even) hours, providing performance metrics. The following graphs being updated every two (odd) hours.</p>
+        <p>Successful performance tests job build adds new data, but even if a build fails, existing data is retained.</p>
+        <p>Updates occur whenever new successful data is available.</p>
     </body>
-    </html>
+  </html>
 EOT
 }
 
@@ -251,21 +230,36 @@ else
   fi
 fi
 
-# Plot image (graphs) files in png format
-for cps_test_name in "${cps_test_names[@]}"; do
-  buildPlotImage "$cps_test_name.txt" "$cps_test_name.png"
+# Limit the plots to last 100 builds for each test
+for cps_stable_test_name in "${cps_stable_test_names[@]}"; do
+  tail -n 100 "$cps_stable_test_name.txt" > file.tmp && mv file.tmp "$cps_stable_test_name.txt"
 done
-for ncmp_test_name in "${ncmp_test_name_names[@]}"; do
-  buildPlotImage "$ncmp_test_name.txt" "$ncmp_test_name.png"
+for ncmp_stable_test_name in "${ncmp_stable_test_names[@]}"; do
+  tail -n 100 "$ncmp_stable_test_name.txt" > file.tmp && mv file.tmp "$ncmp_stable_test_name.txt"
+done
+for cps_unstable_test_name in "${cps_unstable_test_names[@]}"; do
+  tail -n 100 "$cps_unstable_test_name.txt" > file.tmp && mv file.tmp "$cps_unstable_test_name.txt"
+done
+for ncmp_unstable_test_name in "${ncmp_unstable_test_names[@]}"; do
+  tail -n 100 "$ncmp_unstable_test_name.txt" > file.tmp && mv file.tmp "$ncmp_unstable_test_name.txt"
 done
 
-# Build the summary(index.html) page
-buildMainPageHtmlReport
-
-# Build individual html page reports for each test
-for cps_test_name in "${cps_test_names[@]}"; do
-  buildSubPageHtmlReport "$cps_test_name.png" "$cps_test_name" "$cps_test_name.html"
+# Plot image (graphs) files in png format
+for cps_stable_test_name in "${cps_stable_test_names[@]}"; do
+  buildPlotImage "$cps_stable_test_name.txt" "$cps_stable_test_name.png"
+done
+for ncmp_stable_test_name in "${ncmp_stable_test_names[@]}"; do
+  buildPlotImage "$ncmp_stable_test_name.txt" "$ncmp_stable_test_name.png"
 done
-for ncmp_test_name in "${ncmp_test_name_names[@]}"; do
-  buildSubPageHtmlReport "$ncmp_test_name.png" "$ncmp_test_name" "$ncmp_test_name.html"
+for cps_unstable_test_name in "${cps_unstable_test_names[@]}"; do
+  buildPlotImage "$cps_unstable_test_name.txt" "$cps_unstable_test_name.png"
 done
+for ncmp_unstable_test_name in "${ncmp_unstable_test_names[@]}"; do
+  buildPlotImage "$ncmp_unstable_test_name.txt" "$ncmp_unstable_test_name.png"
+done
+
+# Build the category pages
+buildCategoryHtmlReport cps_stable_test_names[@] "cps stable tests performance review" "cpsStableTestsPerformanceReview.html"
+buildCategoryHtmlReport ncmp_stable_test_names[@] "ncmp stable tests performance review" "ncmpStableTestsPerformanceReview.html"
+buildCategoryHtmlReport cps_unstable_test_names[@] "cps unstable tests performance review" "cpsUnstableTestsPerformanceReview.html"
+buildCategoryHtmlReport ncmp_unstable_test_names[@] "ncmp unstable tests performance review" "ncmpUnstableTestsPerformanceReview.html"
index 00b8b281a0b779d0cb9040ffa4c88ea35b9def2f..78e89745639b3013e4d0e2d1ce922dbad82b29b2 100644 (file)
       - shell:
           !include-raw-escape: ./verify-policy-csit.sh
 
+# A job to plot the result of cps performance test
 - job-template:
     name: 'onap-{project-name}-performance-tests-plots'
     disabled_job_var: false
       - html-publisher:
           name: "Performance Review"
           dir: "."
-          files: "index.html,createOperation.html,readOperation.html,updateOperation.html,deleteOperation.html"
+          files: "cpsStableTestsPerformanceReview.html,ncmpStableTestsPerformanceReview.html,cpsUnstableTestsPerformanceReview.html,ncmpUnstableTestsPerformanceReview.html"
 
+# A job to trigger performance test which are based on K6 Framework on cps project
+- job-template:
+    name: 'onap-{project-name}-performance-test-k6'
+    disabled_job_var: false
+    node: xerces-cps-hw
+    wipe_workspace: false
+
+    triggers:
+      - timed: '{timer}'
+
+    builders:
+      - shell:
+          !include-raw-escape: ./cps/k6-performance-tests-trigger.sh
+
+# A job to perform performance test which are based on Spock-Groovy Framework on cps project
 - job-template:
     name: 'onap-{project-name}-{stream}-performance-test-java'
     disabled_job_var: false
index 77355147ba7a43e775bd449762636486b61b39fe..f659c711889686528e134238efc3cf57f2f85981 100644 (file)
@@ -13,13 +13,15 @@ sudo apt-get install -y python3-venv
 sudo apt-get install -y python3-dev gcc
 
 echo "----------------------------------------------------"
-echo "Install Docker compose if needed"
+echo "Install Docker Compose if needed"
 echo "----------------------------------------------------"
-if [ -f /usr/local/bin/docker-compose ]; then
+if [ -f /usr/local/lib/docker/cli-plugins/docker-compose ]; then
   echo "Docker compose already installed"
 else
-  sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
-  sudo chmod +x /usr/local/bin/docker-compose
+  echo "Installing Docker Compose"
+  sudo mkdir -p /usr/local/lib/docker/cli-plugins
+  sudo curl -SL https://github.com/docker/compose/releases/download/v2.27.0/docker-compose-linux-x86_64 -o /usr/local/lib/docker/cli-plugins/docker-compose
+  sudo chmod +x /usr/local/lib/docker/cli-plugins/docker-compose
 fi
 
 unset WORKSPACE