From bc7b1438041402599cdcff0433c4c8ab62c8348d Mon Sep 17 00:00:00 2001 From: Alexandru Avadanii Date: Tue, 7 Apr 2020 12:34:34 +0200 Subject: [PATCH] iec: aarch64 baremetal POD: map name, cron trigger IEC Fuel deploy scripts need a mapping between the Jenkins node (slave) name and its lab/pod naming scheme, i.e. for the new baremetal POD `ubuntu1804-dev-96c-256g-1` we will use `arm-baremetal1` for PDF/IDF filenames. While at it, update related jobs: - extend ci-management static slave init jobs to also generate jobs for the new AArch64 baremetal POD label (aarch64_baremetal_dev). - exclude Ubuntu 16.04 / CentOS from Fuel baremetal job matrix since baremetal provisioning in Fuel only supports Ubuntu 18.04 currently; - schedule IEC Type 2 Fuel baremetal deployment every day @ 01:00; - fix GERRIT_REFSPEC job paramater being ignored for IEC jobs; JIRA: IT-19425 JIRA: IT-19445 Change-Id: I1e1debb7ad61e6aac7a6304ecc2bd5fd6e9fe3ce Signed-off-by: Alexandru Avadanii --- jjb/akraino-templates/akraino-iec-macros.yaml | 10 +--------- jjb/akraino-templates/akraino-iec-templates.yaml | 7 +++---- jjb/ci-management/static-slaves-ci-jobs.yaml | 1 + jjb/iec/iec-fuel-deploy.sh | 6 +++++- jjb/iec/iec.yaml | 13 +++++++++---- 5 files changed, 19 insertions(+), 18 deletions(-) diff --git a/jjb/akraino-templates/akraino-iec-macros.yaml b/jjb/akraino-templates/akraino-iec-macros.yaml index 58bbbc4..8b21f63 100644 --- a/jjb/akraino-templates/akraino-iec-macros.yaml +++ b/jjb/akraino-templates/akraino-iec-macros.yaml @@ -89,10 +89,6 @@ name: 'iec-type2-fuel-virtual-ubuntu1604-daily-master-trigger' triggers: - timed: '0 1 * * 1,3,5' -- trigger: - name: 'iec-type2-fuel-baremetal-ubuntu1604-daily-master-trigger' - triggers: - - timed: '' - trigger: name: 'iec-type2-compass-virtual-ubuntu1604-daily-master-trigger' triggers: @@ -104,15 +100,11 @@ - trigger: name: 'iec-type2-fuel-baremetal-ubuntu1804-daily-master-trigger' triggers: - - timed: '' + - timed: '0 1 * * *' - trigger: name: 'iec-type2-fuel-virtual-centos7-daily-master-trigger' triggers: - timed: '0 1 * * 4,7' -- trigger: - name: 'iec-type2-fuel-baremetal-centos7-daily-master-trigger' - triggers: - - timed: '' - trigger: name: 'iec-type1-compass-virtual-ubuntu1604-daily-master-trigger' triggers: diff --git a/jjb/akraino-templates/akraino-iec-templates.yaml b/jjb/akraino-templates/akraino-iec-templates.yaml index 15664d4..df14cbe 100644 --- a/jjb/akraino-templates/akraino-iec-templates.yaml +++ b/jjb/akraino-templates/akraino-iec-templates.yaml @@ -62,7 +62,7 @@ - project: !j2: | {%- for uc in usecase -%} - iec-{{ iecType }}-install-{{ uc | first }}-{{ installer }}-{{ deploy_type }}-{{ os }}-daily-{{ stream }} + iec-{{ iecType }}-install-{{ uc }}-{{ installer }}-{{ deploy_type }}-{{ os }}-daily-{{ stream }} {%- if not loop.last -%},{%- endif -%} {%- endfor %} current-parameters: true @@ -124,9 +124,8 @@ - git: credentials-id: '{jenkins-ssh-credential}' url: '{git-url}/{project}.git' - refspec: '' - branches: - - 'refs/heads/{branch}' + refspec: '$GERRIT_REFSPEC' + branches: '$GERRIT_BRANCH' skip-tag: true wipe-workspace: true submodule: diff --git a/jjb/ci-management/static-slaves-ci-jobs.yaml b/jjb/ci-management/static-slaves-ci-jobs.yaml index c07b550..bb36b03 100644 --- a/jjb/ci-management/static-slaves-ci-jobs.yaml +++ b/jjb/ci-management/static-slaves-ci-jobs.yaml @@ -11,6 +11,7 @@ - aarch64_dev - aarch64_build - aarch64_baremetal + - aarch64_baremetal_dev jobs: - akraino-project-build-node-init diff --git a/jjb/iec/iec-fuel-deploy.sh b/jjb/iec/iec-fuel-deploy.sh index e7ecb1e..2e1fbc9 100644 --- a/jjb/iec/iec-fuel-deploy.sh +++ b/jjb/iec/iec-fuel-deploy.sh @@ -17,7 +17,11 @@ if [ "$(uname -m)" = 'aarch64' ]; then LAB_NAME='arm' # shellcheck disable=SC2153 POD_NAME=${NODE_NAME/*ubuntu1804-dev-48c-256g-/virtual} -else + if [[ ! "$POD_NAME" =~ virtual ]]; then + POD_NAME=${NODE_NAME/*ubuntu1804-dev-96c-256g-/baremetal} + fi +fi +if [[ ! "$POD_NAME" =~ (virtual|baremetal) ]]; then echo "Unavailable hardware. Cannot continue!" exit 1 fi diff --git a/jjb/iec/iec.yaml b/jjb/iec/iec.yaml index 625017d..d7a5e1e 100644 --- a/jjb/iec/iec.yaml +++ b/jjb/iec/iec.yaml @@ -43,7 +43,7 @@ # ------------------------------- deploy_type: - baremetal: - slave-label: 'aarch64_dev' + slave-label: 'aarch64_baremetal_dev' scenario: 'k8-calico-iec-noha' - virtual: slave-label: 'aarch64_dev' @@ -59,14 +59,19 @@ os: ubuntu1804 - iecType: type1 installer: fuel + # Fuel baremetal provisioning only supports Ubuntu 18.04 + - installer: fuel + deploy_type: baremetal + os: centos7 + - installer: fuel + deploy_type: baremetal + os: ubuntu1604 # ------------------------------- # USECASE DEFINITIONS # ------------------------------- usecase: - - seba_on_arm: - slave-label: 'aarch64_dev' - scenario: 'k8-calico-iec-noha' + - seba_on_arm jobs: - akraino-iec-install -- 2.16.6