Skip to content

Commit 1431ff6

Browse files
committed
[CI] issue: HPCINFRA-3388 Run all CI steps on containers
Today we have a few CI pipelines that still use nodeLabel: 'master' in their matrix file, causing some steps to run on the master node. This is a security risk and we should run only on containers, the master node will be taken down in the future not allowing this type of run. Removed weekly dr job that uses nodelabel definition, move this ability to the release pipeline Signed-off-by: NirWolfer <[email protected]>
1 parent 594c2d2 commit 1431ff6

File tree

5 files changed

+12
-161
lines changed

5 files changed

+12
-161
lines changed

.ci/do_release.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ if [ -z "${do_release}" ]; then
4343
do_release=false
4444
fi
4545

46+
# Checkout the release tag
47+
git checkout tags/${release_tag}
48+
4649
MAJOR_VERSION=$(grep -e "define(\[prj_ver_major\]" configure.ac | awk '{ printf $2 };' | sed 's/)//g')
4750
MINOR_VERSION=$(grep -e "define(\[prj_ver_minor\]" configure.ac | awk '{ printf $2 };' | sed 's/)//g')
4851
REVISION_VERSION=$(grep -e "define(\[prj_ver_revision\]" configure.ac | awk '{ printf $2 };' | sed 's/)//g')

.ci/pipeline/dr_weekly_jjb.yaml

Lines changed: 0 additions & 68 deletions
This file was deleted.

.ci/pipeline/dr_weekly_matrix.yaml

Lines changed: 0 additions & 91 deletions
This file was deleted.

.ci/pipeline/release_jjb.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@
4343
name: "conf_file"
4444
default: ".ci/pipeline/release_matrix_job.yaml"
4545
description: "job config file. Do not change it"
46+
- bool:
47+
name: "do_dr_build"
48+
default: false
49+
description: "Build DR weekly"
4650
pipeline-scm:
4751
scm:
4852
- git:

.ci/pipeline/release_matrix_job.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ kubernetes:
1515
arch_table:
1616
x86_64:
1717
nodeSelector: 'kubernetes.io/arch=amd64'
18-
jnlpImage: 'harbor.mellanox.com/toolbox/c3po-jnlp:latest'
18+
jnlpImage: 'nbu-harbor.gtm.nvidia.com/toolbox/c3po-jnlp:latest'
1919

2020
env:
2121
MAIL_FROM: [email protected]
@@ -55,6 +55,9 @@ pipeline_start:
5555
shell: action
5656
module: groovy
5757
run: |
58+
if (params.do_dr_build) {
59+
env.release_tag = sh (returnStdout: true, script: "git describe --tags --abbrev=0 2>/dev/null").trim()
60+
}
5861
echo "Starting release process for LibXLIO-${release_tag}"
5962
currentBuild.displayName += "-${release_tag}"
6063
@@ -66,7 +69,7 @@ pipeline_stop:
6669
mail from: "${MAIL_FROM}",
6770
mimeType: 'text/html',
6871
to: "${notification_email}",
69-
subject: "Release build ended for LibXLIO - ${release_tag}",
72+
subject: "${params.do_dr_build ? 'Weekly DR' : 'Release'} build ended for LibXLIO - ${release_tag}",
7073
body: """
7174
<p><b>Tag:</b> ${release_tag}</p>
7275
<p><b>Build url:</b> <a href=${currentBuild.absoluteUrl}>link</a></p>

0 commit comments

Comments
 (0)