diff --git a/ci/jenkins/Jenkinsfile_py3-master_gpu_doc b/ci/jenkins/Jenkinsfile_py3-master_gpu_doc index 829d992c7b..5718200fe9 100644 --- a/ci/jenkins/Jenkinsfile_py3-master_gpu_doc +++ b/ci/jenkins/Jenkinsfile_py3-master_gpu_doc @@ -67,13 +67,23 @@ core_logic: { set +e conda activate ./conda/cpu/py3 - python3 ci/batch/submit-job.py --region us-east-1 --wait \ - --timeout 1800 --saved-output ./docs/examples --conda-env docker/py3 \ - --name GluonNLP-${env.BRANCH_NAME}-${env.BUILD_NUMBER} \ - --save-path batch/${env.BRANCH_NAME}/${env.BUILD_NUMBER}/docs/examples \ - --work-dir . --source-ref refs/pull/${env.CHANGE_ID}/head \ - --command \"python3 docs/md2ipynb.py ${md_file} > ${stdout_file} 2> ${stderr_file} \" - BATCH_EXIT_CODE=\$? + if [ '${env.BRANCH_NAME}' = 'master' ]; then + python3 ci/batch/submit-job.py --region us-east-1 --wait \ + --timeout 1800 --saved-output ./docs/examples --conda-env docker/py3 \ + --name GluonNLP-${env.BRANCH_NAME}-${env.BUILD_NUMBER} \ + --save-path batch/${env.BRANCH_NAME}/${env.BUILD_NUMBER}/docs/examples \ + --work-dir . \ + --command \"python3 docs/md2ipynb.py ${md_file} > ${stdout_file} 2> ${stderr_file} \" + BATCH_EXIT_CODE=\$? + else + python3 ci/batch/submit-job.py --region us-east-1 --wait \ + --timeout 1800 --saved-output ./docs/examples --conda-env docker/py3 \ + --name GluonNLP-${env.BRANCH_NAME}-${env.BUILD_NUMBER} \ + --save-path batch/${env.BRANCH_NAME}/${env.BUILD_NUMBER}/docs/examples \ + --work-dir . --source-ref refs/pull/${env.CHANGE_ID}/head \ + --command \"python3 docs/md2ipynb.py ${md_file} > ${stdout_file} 2> ${stderr_file} \" + BATCH_EXIT_CODE=\$? + fi aws s3api wait object-exists --bucket gluon-nlp-staging \ --key batch/${env.BRANCH_NAME}/${env.BUILD_NUMBER}/${stderr_file}