From 0c59b2482d421ea18de6672c435284eb558ace0f Mon Sep 17 00:00:00 2001 From: Fatih Degirmenci Date: Tue, 24 Mar 2020 18:56:21 +0000 Subject: [PATCH] Configure parameters for ONAP baremetal deployments Change-Id: Iae5a317b1dc2518ec78e801432c9f3b3eb5087a7 --- .../cloud-infra-periodic-onap-baremetal.yaml | 44 +++++-------------- jjb/cloud-infra/onap-deploy-baremetal.sh | 4 +- jjb/cloud-infra/onap-healthcheck-baremetal.sh | 33 -------------- jjb/cloud-infra/onap-healthcheck.sh | 3 +- jjb/cloud-infra/onap-macros.yaml | 43 +++++++++++++++++- jjb/cloud-infra/oom-healthcheck.sh | 3 +- 6 files changed, 58 insertions(+), 72 deletions(-) delete mode 100644 jjb/cloud-infra/onap-healthcheck-baremetal.sh diff --git a/jjb/cloud-infra/cloud-infra-periodic-onap-baremetal.yaml b/jjb/cloud-infra/cloud-infra-periodic-onap-baremetal.yaml index 646888022..338694770 100644 --- a/jjb/cloud-infra/cloud-infra-periodic-onap-baremetal.yaml +++ b/jjb/cloud-infra/cloud-infra-periodic-onap-baremetal.yaml @@ -34,7 +34,7 @@ onap-version: elalto onap-flavor: full engine-version: master - engine-refspec: 'refs/changes/57/4157/2' + engine-refspec: 'refs/changes/57/4157/12' deploy-scenario: 'onap-nofeature-noha' deploy-scenario-version: master deploy-scenario-refspec: master @@ -44,7 +44,7 @@ onap-version: master onap-flavor: full engine-version: master - engine-refspec: master + engine-refspec: 'refs/changes/57/4157/12' deploy-scenario: 'onap-nofeature-noha' deploy-scenario-version: master deploy-scenario-refspec: master @@ -63,7 +63,7 @@ onap-other-phases: - onap-deploy: - build-timeout: 210 + build-timeout: 420 - oom-hc: build-timeout: 30 test-type: oom-healthcheck @@ -106,7 +106,7 @@ project: '{project}' branch: '{nordix-branch}' - nordix-gerrit-parameters - - onap-parameter-macro + - onap-baremetal-parameter-macro - label: name: SLAVE_LABEL default: '{slave-label}' @@ -265,7 +265,7 @@ INSTALLER_TYPE=$INSTALLER_TYPE DEPLOY_SCENARIO=$DEPLOY_SCENARIO ONAP_VERSION=$ONAP_VERSION - ONAP_FLAVOR=core + ONAP_FLAVOR=small TEST_TYPE=onap-healthcheck POD_NAME=$POD_NAME ENGINE_VERSION=$ENGINE_VERSION @@ -286,7 +286,7 @@ INSTALLER_TYPE=$INSTALLER_TYPE DEPLOY_SCENARIO=$DEPLOY_SCENARIO ONAP_VERSION=$ONAP_VERSION - ONAP_FLAVOR=core + ONAP_FLAVOR=medium TEST_TYPE=onap-healthcheck POD_NAME=$POD_NAME ENGINE_VERSION=$ENGINE_VERSION @@ -307,7 +307,7 @@ INSTALLER_TYPE=$INSTALLER_TYPE DEPLOY_SCENARIO=$DEPLOY_SCENARIO ONAP_VERSION=$ONAP_VERSION - ONAP_FLAVOR=core + ONAP_FLAVOR=full TEST_TYPE=onap-healthcheck POD_NAME=$POD_NAME ENGINE_VERSION=$ENGINE_VERSION @@ -328,7 +328,7 @@ INSTALLER_TYPE=$INSTALLER_TYPE DEPLOY_SCENARIO=$DEPLOY_SCENARIO ONAP_VERSION=$ONAP_VERSION - ONAP_FLAVOR=core + ONAP_FLAVOR=healthdist TEST_TYPE=onap-healthcheck POD_NAME=$POD_NAME ENGINE_VERSION=$ENGINE_VERSION @@ -381,15 +381,11 @@ project: '{project}' branch: '{nordix-branch}' - nordix-gerrit-parameters - - onap-parameter-macro + - onap-baremetal-parameter-macro - label: name: SLAVE_LABEL default: 'xerces-jumphost-onap-ubuntu1804' description: 'Slave label to schedule this job on. All slaves have Ubuntu1604 no matter what distro target nodes use' - - string: - name: OPENSTACK_CLOUD_PROVIDER - default: 'city' - description: 'Name of the cloud where this job is run' - string: name: DISTRO default: 'ubuntu1804' @@ -402,14 +398,6 @@ name: ONAP_VERSION default: '{onap-version}' description: 'ONAP version to deploy' - - string: - name: HEAT_ENVIRONMENT_FILENAME - default: "heat-environment-full.yaml" - description: 'Type of the deployment' - - string: - name: HEAT_ENVIRONMENT_FILE - default: "file:///opt/engine/.cache/repos/swconfig/scenarios/$DEPLOY_SCENARIO/$INSTALLER_TYPE/role/$DEPLOY_SCENARIO/files/$HEAT_ENVIRONMENT_FILENAME" - description: 'Type of the deployment' wrappers: - mask-passwords @@ -454,15 +442,11 @@ project: '{project}' branch: '{nordix-branch}' - nordix-gerrit-parameters - - onap-parameter-macro + - onap-baremetal-parameter-macro - label: name: SLAVE_LABEL default: 'xerces-jumphost-onap-ubuntu1804' description: 'Slave label to schedule this job on. All slaves have Ubuntu1604 no matter what distro target nodes use' - - string: - name: OPENSTACK_CLOUD_PROVIDER - default: 'city' - description: 'Name of the cloud where this job is run' - string: name: DISTRO default: 'ubuntu1804' @@ -471,14 +455,6 @@ name: ONAP_VERSION default: '{onap-version}' description: 'ONAP version to deploy' - - string: - name: HEAT_ENVIRONMENT_FILENAME - default: "heat-environment-full.yaml" - description: 'Type of the deployment' - - string: - name: HEAT_ENVIRONMENT_FILE - default: "file:///opt/engine/.cache/repos/swconfig/scenarios/$DEPLOY_SCENARIO/$INSTALLER_TYPE/role/$DEPLOY_SCENARIO/files/$HEAT_ENVIRONMENT_FILENAME" - description: 'Type of the deployment' - string: name: ENGINE_VERSION default: '{engine-version}' diff --git a/jjb/cloud-infra/onap-deploy-baremetal.sh b/jjb/cloud-infra/onap-deploy-baremetal.sh index 42cc7cfe2..3b982b51c 100644 --- a/jjb/cloud-infra/onap-deploy-baremetal.sh +++ b/jjb/cloud-infra/onap-deploy-baremetal.sh @@ -22,7 +22,6 @@ set -o errexit set -o nounset cd $WORKSPACE -/bin/rm -f ../inventory.ini echo "Info: Preparing for ONAP deployment" # checkout given engine version @@ -72,5 +71,6 @@ cd $WORKSPACE -i "https://gerrit.nordix.org/gitweb?p=infra/hwconfig.git;a=blob_plain;f=pods/${NODE_NAME}-idf.yml" cd $WORKSPACE -/bin/cp /opt/engine/.cache/config/inventory.ini ../inventory.ini +/bin/cp -f /opt/engine/.cache/config/inventory.ini ../inventory.ini || true +/bin/cp -f /opt/engine/.cache/config/inventory.ini /tmp/inventory.ini || true # vim: set ts=2 sw=2 expandtab: diff --git a/jjb/cloud-infra/onap-healthcheck-baremetal.sh b/jjb/cloud-infra/onap-healthcheck-baremetal.sh deleted file mode 100644 index 6099d0bf2..000000000 --- a/jjb/cloud-infra/onap-healthcheck-baremetal.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash - -# ============LICENSE_START======================================================= -# Copyright (C) 2019 The Nordix Foundation. All rights reserved. -# ================================================================================ -# 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========================================================= - -set -o errexit -set -o nounset - -cd $WORKSPACE -echo "Info: Starting ${TEST_TYPE}-${ONAP_FLAVOR} using Xtesting" -echo "-------------------------------------------------------------------------" -echo "Info: Cloning opnfv/xtesting-onap repository" -cd $HOME && /bin/rm -rf $WORKSPACE -git clone -q $XTESTING_REPO_URL $WORKSPACE && cd $WORKSPACE -cp /tmp/inventory.ini inventory/inventory.ini -$WORKSPACE/xtesting.sh - -# vim: set ts=2 sw=2 expandtab: diff --git a/jjb/cloud-infra/onap-healthcheck.sh b/jjb/cloud-infra/onap-healthcheck.sh index 6099d0bf2..9f1e33155 100644 --- a/jjb/cloud-infra/onap-healthcheck.sh +++ b/jjb/cloud-infra/onap-healthcheck.sh @@ -27,7 +27,8 @@ echo "-------------------------------------------------------------------------" echo "Info: Cloning opnfv/xtesting-onap repository" cd $HOME && /bin/rm -rf $WORKSPACE git clone -q $XTESTING_REPO_URL $WORKSPACE && cd $WORKSPACE -cp /tmp/inventory.ini inventory/inventory.ini +/bin/cp -f /opt/engine/.cache/config/inventory.ini /tmp/inventory.ini || true +/bin/cp -f /tmp/inventory.ini inventory/inventory.ini || true $WORKSPACE/xtesting.sh # vim: set ts=2 sw=2 expandtab: diff --git a/jjb/cloud-infra/onap-macros.yaml b/jjb/cloud-infra/onap-macros.yaml index 0771a145b..55b92c971 100644 --- a/jjb/cloud-infra/onap-macros.yaml +++ b/jjb/cloud-infra/onap-macros.yaml @@ -18,7 +18,7 @@ # SPDX-License-Identifier: Apache-2.0 # ============LICENSE_END========================================================= -# macros used by all job types +# macros used by all job types on cloud - parameter: name: 'onap-parameter-macro' parameters: @@ -59,6 +59,47 @@ default: '' description: 'Extra parameters that can be added when run the play books.' +# macros used by all job types on baremetal +- parameter: + name: 'onap-baremetal-parameter-macro' + parameters: + - string: + name: PROVISIONER_TYPE + default: 'bifrost' + description: 'Provisioner to use for provisioning nodes' + - string: + name: INSTALLER_TYPE + default: 'kubespray' + description: 'Installer to use for deploying the scenario' + - string: + name: DEPLOY_SCENARIO + default: 'onap-nofeature-noha' + description: 'Scenario to deploy and test' + - string: + name: DEPLOY_TYPE + default: 'baremetal' + description: 'Type of the deployment' + - string: + name: TEST_TYPE + default: 'oom-healthcheck' + description: 'Test type to run. Could be oom-healthcheck or onap-healthcheck' + - string: + name: NORDIX_ARM_REPO_URL + default: 'https://artifactory.nordix.org/artifactory' + description: 'URL to Nordix Artifactory' + - string: + name: NORDIX_HARBOR_REPO_URL + default: 'registry.nordix.org' + description: 'URL to Nordix Harbor' + - string: + name: XTESTING_REPO_URL + default: 'https://gerrit.nordix.org/opnfv/xtesting-onap.git' + description: 'URL to Nordix xtesting-onap repository' + - string: + name: ENGINE_ANSIBLE_PARAMS + default: '' + description: 'Extra parameters that can be added when run the play books.' + - builder: name: 'onap-deploy-macro' builders: diff --git a/jjb/cloud-infra/oom-healthcheck.sh b/jjb/cloud-infra/oom-healthcheck.sh index 6099d0bf2..9f1e33155 100644 --- a/jjb/cloud-infra/oom-healthcheck.sh +++ b/jjb/cloud-infra/oom-healthcheck.sh @@ -27,7 +27,8 @@ echo "-------------------------------------------------------------------------" echo "Info: Cloning opnfv/xtesting-onap repository" cd $HOME && /bin/rm -rf $WORKSPACE git clone -q $XTESTING_REPO_URL $WORKSPACE && cd $WORKSPACE -cp /tmp/inventory.ini inventory/inventory.ini +/bin/cp -f /opt/engine/.cache/config/inventory.ini /tmp/inventory.ini || true +/bin/cp -f /tmp/inventory.ini inventory/inventory.ini || true $WORKSPACE/xtesting.sh # vim: set ts=2 sw=2 expandtab: -- 2.25.1