Commit d5a0403b authored by xujian's avatar xujian

优化

parent 46676fc9
......@@ -21,6 +21,7 @@ pipeline {
agent any
parameters {
booleanParam(name: 'TAR', defaultValue: false, description: '打包成Tar') //
gitParameter branchFilter: 'origin/(.*)', defaultValue: defaultBranch, name: 'BASE', type: 'PT_BRANCH_TAG', useRepository: '.*factory-tobacco-basic.git' // 后端
gitParameter branchFilter: 'origin/(.*)', defaultValue: defaultBranch, name: 'CORE', type: 'PT_BRANCH_TAG', useRepository: '.*factory-tobacco-qrcodecore.git' // 后端
gitParameter branchFilter: 'origin/(.*)', defaultValue: defaultBranch, name: 'HTJ', type: 'PT_BRANCH_TAG', useRepository: '.*factory-tobacco-qrcode-htj.git' // 后端
......@@ -144,7 +145,7 @@ pipeline {
sh "docker push ${push_path}/${module.name}:${module.version}"
sh "docker images -f 'dangling=true' -q | xargs -r docker rmi"
}
if (module.isUpdate) {
if (module.isUpdate && params.TAR) {
sh "docker tag ${push_path}/${module.name}:${module.version} ${module.name}:${module.version}"
sh "cd Docker/images && docker save -o ${module.name}-${module.version}.tar ${module.name}:${module.version}"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment