another attempte to running the blasted if
This commit is contained in:
parent
e9de8d3aaf
commit
a1b6f3d9f7
@ -67,6 +67,17 @@ pipeline {
|
||||
""",
|
||||
returnStdout: true
|
||||
).trim()
|
||||
if (k8slensVersion ==~ 'refs\\/tags\\/([5-9]|[0-9]{2,})\\.[0-9]+\\.[0-9]+$') {
|
||||
if (k8slensVersion ==~ 'refs\\/tags\\/5\\.5\\.[0-9]+$') {
|
||||
echo "Version (${k8slensVersion}) is valid, we will build it with node 14."
|
||||
jsNodeID = 'node-14'
|
||||
} else if (k8slensVersion ==~ 'refs\\/tags\\/5\\.6\\.[0-9]+$') {
|
||||
echo "Version (${k8slensVersion}) is valid, we will build it with node 16."
|
||||
jsNodeID = 'node-16'
|
||||
}
|
||||
echo "Version (${k8slensVersion}) is not valid, we will not build it."
|
||||
skipBuild = false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -75,17 +86,6 @@ pipeline {
|
||||
stage('Pull K8S Lens Source Code') {
|
||||
when {
|
||||
expression {
|
||||
if (k8slensVersion ==~ 'refs\\/tags\\/([5-9]|[0-9]{2,})\\.[0-9]+\\.[0-9]+$') {
|
||||
if (k8slensVersion ==~ 'refs\\/tags\\/5\\.5\\.[0-9]+$') {
|
||||
echo "Version (${k8slensVersion}) is valid, we will build it with node 14."
|
||||
jsNodeID = 'node-14'
|
||||
} else if (k8slensVersion ==~ 'refs\\/tags\\/5\\.6\\.[0-9]+$') {
|
||||
echo "Version (${k8slensVersion}) is valid, we will build it with node 16."
|
||||
jsNodeID = 'node-16'
|
||||
}
|
||||
echo "Version (${k8slensVersion}) is not valid, we will not build it."
|
||||
skipBuild = false
|
||||
}
|
||||
return skipBuild
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user