fix(pipeline): update steps.withCredentials to use steps.usernamePassword for authentication

Signed-off-by: 孙振宇 <>
This commit is contained in:
孙振宇 2025-02-10 01:26:11 +08:00
parent a92eb07a9b
commit a02715efa7

View File

@ -27,7 +27,7 @@ class ImageBuilder {
architectures = ['linux/amd64']
}
steps.withCredentials([usernamePassword(credentialsId: registryCredentialsId, passwordVariable: 'DOCKER_PASSWORD', usernameVariable: 'DOCKER_USERNAME')]) {
steps.withCredentials([steps.usernamePassword(credentialsId: registryCredentialsId, passwordVariable: 'DOCKER_PASSWORD', usernameVariable: 'DOCKER_USERNAME')]) {
steps.log.info("ImageBuilder", "Authentication to ${registry}")
switch(builderType) {
case ImageBuilderTypes.DOCKER_IN_DOCKER: