Authenticate when pulling io.spring.docresources:spring-doc-resources from Arifactory repo.spring.io/release repository.

This commit is contained in:
John Blum
2023-05-31 10:17:55 -07:00
parent 54a1e94df9
commit 8ff6f9f4d3
2 changed files with 39 additions and 7 deletions

14
Jenkinsfile vendored
View File

@@ -64,12 +64,14 @@ pipeline {
script {
docker.image(p['docker.container.image.java.main']).inside(p['docker.container.inside.env.basic']) {
withCredentials([file(credentialsId: 'docs.spring.io-jenkins_private_ssh_key', variable: 'DEPLOY_SSH_KEY')]) {
try {
sh "ci/deployDocs.sh"
}
catch (e) {
currentBuild.result = "FAILED: deploy docs"
throw e
withCredentials([usernamePassword(credentialsId: p['artifactory.credentials'], usernameVariable: 'ARTIFACTORY_USERNAME', passwordVariable: 'ARTIFACTORY_PASSWORD')]) {
try {
sh "ci/deployDocs.sh"
}
catch (e) {
currentBuild.result = "FAILED: deploy docs"
throw e
}
}
}
}