ci: 改进镜像名称的生成规则以支持更多字符
将镜像名称生成规则中的空格替换改为替换所有非字母数字、点和横线的字符,以避免潜在的命名冲突
This commit is contained in:
Vendored
+1
-1
@@ -5,7 +5,7 @@ pipeline {
|
|||||||
REGISTRY = 'git.virtheart.com'
|
REGISTRY = 'git.virtheart.com'
|
||||||
REGISTRY_OWNER = 'virtheart'
|
REGISTRY_OWNER = 'virtheart'
|
||||||
REGISTRY_USERNAME = 'chenchun@virtheart.com'
|
REGISTRY_USERNAME = 'chenchun@virtheart.com'
|
||||||
IMAGE_NAME = "${env.JOB_NAME.replace(' ', '-').toLowerCase()}"
|
IMAGE_NAME = "${env.JOB_NAME.replaceAll(/[^a-zA-Z0-9.-]/, '-').toLowerCase()}"
|
||||||
IMAGE_TAG = "${env.BUILD_NUMBER}"
|
IMAGE_TAG = "${env.BUILD_NUMBER}"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user