summaryrefslogtreecommitdiff
path: root/vars/buildPackage.groovy
diff options
context:
space:
mode:
Diffstat (limited to 'vars/buildPackage.groovy')
-rw-r--r--vars/buildPackage.groovy14
1 files changed, 9 insertions, 5 deletions
diff --git a/vars/buildPackage.groovy b/vars/buildPackage.groovy
index ca901481..fde5e59a 100644
--- a/vars/buildPackage.groovy
+++ b/vars/buildPackage.groovy
@@ -37,11 +37,6 @@ def call(description=null, pkgList=null, buildCmd=null, buildArm=false) {
agent {
label "ec2_amd64"
}
- environment {
- // get relative directory path to Jenkinsfile
- BASE_DIR = getJenkinsfilePath()
- CHANGESET_DIR = getChangeSetPath()
- }
steps {
script {
// create container name on demand
@@ -62,6 +57,15 @@ def call(description=null, pkgList=null, buildCmd=null, buildArm=false) {
}
}
stage('Build Code') {
+ when {
+ beforeOptions true
+ beforeAgent true
+ anyOf {
+ changeset pattern: getChangeSetPath()
+ expression { isPullRequest() }
+ triggeredBy cause: "UserIdCause"
+ }
+ }
parallel {
stage('amd64') {
agent {