diff --git a/Jenkinsfile b/Jenkinsfile index 93a9a23ac621..91d99d773728 100755 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -53,6 +53,21 @@ ci_qemu = "tlcpack/ci-qemu:v0.07" ci_arm = "tlcpack/ci-arm:v0.06" // <--- End of regex-scanned config. +// Parameters to allow overriding (in Jenkins UI), the images +// to be used by a given build. When provided, they take precedence +// over default values above. +properties([ + parameters([ + string(name: 'ci_lint_param', defaultValue: ""), + string(name: 'ci_cpu_param', defaultValue: ""), + string(name: 'ci_gpu_param', defaultValue: ""), + string(name: 'ci_wasm_param', defaultValue: ""), + string(name: 'ci_i386_param', defaultValue: ""), + string(name: 'ci_qemu_param', defaultValue: ""), + string(name: 'ci_arm_param', defaultValue: "") + ]) +]) + // tvm libraries tvm_runtime = "build/libtvm_runtime.so, build/config.cmake" tvm_lib = "build/libtvm.so, " + tvm_runtime @@ -107,6 +122,30 @@ def cancel_previous_build() { cancel_previous_build() +stage('Prepare') { + node('CPU') { + // When something is provided in ci_*_param, use it, otherwise default with ci_* + ci_lint = ci_lint_param ?: ci_lint + ci_cpu = ci_cpu_param ?: ci_cpu + ci_gpu = ci_gpu_param ?: ci_gpu + ci_wasm = ci_wasm_param ?: ci_wasm + ci_i386 = ci_i386_param ?: ci_i386 + ci_qemu = ci_qemu_param ?: ci_qemu + ci_arm = ci_arm_param ?: ci_arm + + sh """ + echo "Docker images being used in this build:" + echo " ci_lint = ${ci_lint}" + echo " ci_cpu = ${ci_cpu}" + echo " ci_gpu = ${ci_gpu}" + echo " ci_wasm = ${ci_wasm}" + echo " ci_i386 = ${ci_i386}" + echo " ci_qemu = ${ci_qemu}" + echo " ci_arm = ${ci_arm}" + """ + } +} + stage("Sanity Check") { timeout(time: max_time, unit: 'MINUTES') { node('CPU') {