更新 'Jenkinsfile'

main
newrain001 11 months ago
parent f2e1a46657
commit 793af6468a
  1. 2
      Jenkinsfile

2
Jenkinsfile vendored

@ -68,7 +68,7 @@ spec:
stage('构建镜像') {
steps {
withCredentials([usernamePassword(credentialsId: '${DOCKER_REPOSITORY_CREDENTIAL_ID}', passwordVariable: 'PASSWORD', usernameVariable: 'USERNAME')]) {
container(name: 'docker', shell: 'sh') {
container(name: 'docker', shell: 'echo') {
sh """
docker build -t ${HARBOR_HOST}/${NAMESPACE_NAME}/${REPOSITORY_NAME}:${TAG} .
docker login ${HARBOR_HOST} --username=${USERNAME} --password=${PASSWORD}

Loading…
Cancel
Save