From 21fd2dd70acd47391a1fa789e24d7c710cd78238 Mon Sep 17 00:00:00 2001 From: CODE <1650192445@qq.com> Date: Mon, 11 Dec 2023 16:47:21 +0800 Subject: [PATCH] jenkinsfile --- ...sfilenew_script_1.3.1_1_insert_report_data | 0 ...lenew_script_1.4.0_1_calc_village_distance | 21 +++++++++++++++++++ 2 files changed, 21 insertions(+) rename jenkinsfilenew_node => jenkinsfilenew_script_1.3.1_1_insert_report_data (100%) create mode 100644 jenkinsfilenew_script_1.4.0_1_calc_village_distance diff --git a/jenkinsfilenew_node b/jenkinsfilenew_script_1.3.1_1_insert_report_data similarity index 100% rename from jenkinsfilenew_node rename to jenkinsfilenew_script_1.3.1_1_insert_report_data diff --git a/jenkinsfilenew_script_1.4.0_1_calc_village_distance b/jenkinsfilenew_script_1.4.0_1_calc_village_distance new file mode 100644 index 00000000..372b5b51 --- /dev/null +++ b/jenkinsfilenew_script_1.4.0_1_calc_village_distance @@ -0,0 +1,21 @@ +podTemplate { + node('pod-templ-jenkins-slave-common') { + + env.IMAGE_NAME = "${IOT_IMAGES_REGISTRY}/${SMARTCITY}/${JOB_NAME}" + env.IMAGE_NAME_SHORT = "${SMARTCITY}/${JOB_NAME}" + env.CODE_ADDR = "${GIT_ADDRESS}/free-sun/Highways4Good.git" + + stage('Run shell') { + git branch: 'dev', credentialsId: 'gitea-builder', url: "${CODE_ADDR}" + + container('image-builder') { + sh''' + /kaniko/executor --context=${BUILD_WORKSPACE} --dockerfile=./scripts/1.4.0/data/1_calc_village_distance/Dockerfilenew --destination=${IMAGE_NAME}:${IMAGE_VERSION} --cache=false --cleanup + ''' + } + + buildName "${IMAGE_NAME_SHORT}:${IMAGE_VERSION}" + buildDescription "${IMAGE_NAME}:${IMAGE_VERSION}" + } + } +} \ No newline at end of file