#1474 - Backport support for new sonatype infrastructure to 1.2.x.

This commit is contained in:
Greg L. Turnquist
2021-02-18 09:11:09 -06:00
parent ff62044d7b
commit 8eb5d01e24
3 changed files with 14 additions and 7 deletions

7
Jenkinsfile vendored
View File

@@ -116,7 +116,7 @@ pipeline {
environment {
ARTIFACTORY = credentials('02bd1690-b54f-4c9f-819d-a77cb7a9822c')
SONATYPE = credentials('oss-token')
SONATYPE = credentials('oss-login')
KEYRING = credentials('spring-signing-secring.gpg')
PASSPHRASE = credentials('spring-gpg-passphrase')
}
@@ -144,6 +144,11 @@ pipeline {
if (RELEASE_TYPE == 'release') {
sh "PROFILE=ci,central ci/build-and-deploy-to-maven-central.sh ${PROJECT_VERSION}"
slackSend(
color: (currentBuild.currentResult == 'SUCCESS') ? 'good' : 'danger',
channel: '#spring-hateoas',
message: "@here Spring HATEOAS ${PROJECT_VERSION} is staged on Sonatype awaiting closure and release.")
} else {
sh "PROFILE=ci,${RELEASE_TYPE} ci/build-and-deploy-to-artifactory.sh"
}

View File

@@ -39,8 +39,10 @@ git config core.commentchar "/"
NOTE: You can chain the previous set of commands together using `&&`.
The pipeline will build and release the "release" branch. It will also build a new a new snapshot and stage it on artifactory.
And if it's a `.RELEASE`, the pipeline will push it out to Maven Central.
The pipeline will build and release the "release" branch. It will also build a new snapshot and stage it on artifactory.
And if it's a `.RELEASE`, the pipeline will push it out to Maven Central. To complete a release on Maven Central, you must login
to the server shown in `pom.xml`, close, and release. This is a stop gap to guard against bad releases accidentally getting pushed
out to Maven Central.
=== Running CI tasks locally

View File

@@ -683,10 +683,10 @@
<extensions>true</extensions>
<configuration>
<serverId>sonatype</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>true</autoReleaseAfterClose>
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>false</autoReleaseAfterClose>
<keepStagingRepositoryOnFailure>true</keepStagingRepositoryOnFailure>
<skipStagingRepositoryClose>false</skipStagingRepositoryClose>
<skipStagingRepositoryClose>true</skipStagingRepositoryClose>
</configuration>
</plugin>
</plugins>
@@ -712,7 +712,7 @@
<distributionManagement>
<repository>
<id>sonatype</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
<url>https://s01.oss.sonatype.org//service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>