@@ -124,9 +124,9 @@ jobs:
124124 with :
125125 servers : |
126126 [{
127- "id": "sonatype-nexus-staging ",
128- "username": "${{ secrets.SONATYPE_USERNAME }}",
129- "password": "${{ secrets.SONATYPE_PASSWORD }}"
127+ "id": "central ",
128+ "username": "${{ secrets.MAVEN_CENTRAL_USERNAME }}",
129+ "password": "${{ secrets.MAVEN_CENTRAL_PASSWORD }}"
130130 }]
131131
132132 - name : Create local staging directory
@@ -148,7 +148,7 @@ jobs:
148148 uses : actions/upload-artifact@v4
149149 with :
150150 name : ${{ matrix.setup }}-local-staging
151- path : ~/local -staging
151+ path : ./prepare-release-workspace/target/central -staging
152152 if-no-files-found : error
153153 include-hidden-files : true
154154
@@ -221,20 +221,20 @@ jobs:
221221 with :
222222 servers : |
223223 [{
224- "id": "sonatype-nexus-staging ",
225- "username": "${{ secrets.SONATYPE_USERNAME }}",
226- "password": "${{ secrets.SONATYPE_PASSWORD }}"
224+ "id": "central ",
225+ "username": "${{ secrets.MAVEN_CENTRAL_USERNAME }}",
226+ "password": "${{ secrets.MAVEN_CENTRAL_PASSWORD }}"
227227 }]
228228
229229 - name : Stage release to local staging directory
230230 working-directory : prepare-release-workspace
231- run : ./mvnw --file pom.xml -Pstage -am -pl boringssl-static clean javadoc:jar package gpg:sign org.sonatype.plugins:nexus-staging -maven-plugin:deploy -DnexusUrl=https://oss.sonatype.org -DserverId=sonatype-nexus-staging -DaltStagingDirectory=local-staging -DskipRemoteStaging=true -DskipTests=true -D'checkstyle.skip=true'
231+ run : ./mvnw --file pom.xml -Pstage -am -pl boringssl-static clean javadoc:jar package gpg:sign org.sonatype.central:central-publishing -maven-plugin:publish -DskipTests=true -D'checkstyle.skip=true'
232232
233233 - name : Upload local staging directory
234234 uses : actions/upload-artifact@v4
235235 with :
236236 name : windows-x86_64-local-staging
237- path : prepare-release-workspace/boringssl-static/local -staging
237+ path : ./ prepare-release-workspace/target/central -staging
238238 if-no-files-found : error
239239 include-hidden-files : true
240240
@@ -298,9 +298,9 @@ jobs:
298298 with :
299299 servers : |
300300 [{
301- "id": "sonatype-nexus-staging ",
302- "username": "${{ secrets.SONATYPE_USERNAME }}",
303- "password": "${{ secrets.SONATYPE_PASSWORD }}"
301+ "id": "central ",
302+ "username": "${{ secrets.MAVEN_CENTRAL_USERNAME }}",
303+ "password": "${{ secrets.MAVEN_CENTRAL_PASSWORD }}"
304304 }]
305305
306306 # Cache .m2/repository
@@ -322,21 +322,21 @@ jobs:
322322
323323 - name : Stage snapshots to local staging directory
324324 working-directory : ./prepare-release-workspace/
325- run : ./mvnw -B -ntp -am -pl openssl-dynamic,boringssl-static clean javadoc:jar package gpg:sign org.sonatype.plugins:nexus-staging -maven-plugin:deploy -DnexusUrl=https://oss.sonatype.org -DserverId=sonatype-nexus-staging -DaltStagingDirectory=$HOME/local-staging -DskipRemoteStaging=true - DskipTests=true -Dgpg.passphrase=${{ secrets.GPG_PASSPHRASE }} -Dgpg.keyname=${{ secrets.GPG_KEYNAME }}
325+ run : ./mvnw -B -ntp -am -pl openssl-dynamic,boringssl-static clean javadoc:jar package gpg:sign org.sonatype.central:central-publishing -maven-plugin:publish - DskipTests=true
326326
327327 - name : Upload local staging directory
328328 uses : actions/upload-artifact@v4
329329 with :
330330 name : ${{ matrix.setup }}-local-staging
331- path : ~/local -staging
331+ path : ./prepare-release-workspace/target/central -staging
332332 if-no-files-found : error
333333 include-hidden-files : true
334334
335335 - name : Rollback release on failure
336336 working-directory : ./prepare-release-workspace/
337337 if : ${{ failure() }}
338338 # Rollback the release in case of an failure
339- run : ./.github/scripts/release_rollback.ps1 release.properties netty/netty-tcnative main
339+ run : bash ./.github/scripts/release_rollback.sh release.properties netty/netty-tcnative main
340340
341341 deploy-staged-release :
342342 runs-on : ubuntu-latest
@@ -391,9 +391,9 @@ jobs:
391391 with :
392392 servers : |
393393 [{
394- "id": "sonatype-nexus-staging ",
395- "username": "${{ secrets.SONATYPE_USERNAME }}",
396- "password": "${{ secrets.SONATYPE_PASSWORD }}"
394+ "id": "central ",
395+ "username": "${{ secrets.MAVEN_CENTRAL_USERNAME }}",
396+ "password": "${{ secrets.MAVEN_CENTRAL_PASSWORD }}"
397397 }]
398398
399399 # Hardcode the staging artifacts that need to be downloaded.
@@ -436,24 +436,27 @@ jobs:
436436
437437 - name : Copy previous build artifacts to local maven repository
438438 working-directory : ./prepare-release-workspace/
439- run : bash ./.github/scripts/install_local_staging .sh ~/.m2/repository ~/windows-x86_64-local-staging/staging ~/macos-aarch64-local-staging/staging ~/macos-x86_64-local-staging/staging ~/centos7-aarch64-local-staging/staging ~/debian7-x86_64-local-staging/staging ~/centos6-x86_64-local-staging/ staging
439+ run : bash ./.github/scripts/local_staging_install_release .sh ~/.m2/repository ~/windows-x86_64-local-staging ~/macos-aarch64-local-staging ~/macos-x86_64-local-staging ~/centos7-aarch64-local-staging ~/debian7-x86_64-local-staging ~/centos6-x86_64-local-staging
440440
441441 - name : Generate uber jar and deploy to local staging.
442442 working-directory : ./prepare-release-workspace/
443443 run : |
444444 mkdir -p ~/uber-local-staging
445- ./mvnw -B --file pom.xml -Puber-snapshot -pl boringssl-static clean package gpg:sign org.sonatype.plugins:nexus-staging -maven-plugin:deploy -DnexusUrl=https://oss.sonatype.org -DserverId=sonatype-nexus-staging -DaltStagingDirectory=$HOME/uber-local-staging -DskipRemoteStaging=true -DskipTests=true
445+ ./mvnw -B --file pom.xml -Puber-staging -pl boringssl-static clean package gpg:sign org.sonatype.central:central-publishing -maven-plugin:publish -DskipTests=true
446446
447447 # This step takes care of merging all the previous staged repositories in a way that will allow us to deploy
448448 # all together with one maven command.
449449 - name : Merge staging repositories
450450 working-directory : ./prepare-release-workspace/
451- run : bash ./.github/scripts/merge_local_staging.sh /home/runner/local-staging/staging ~/windows-x86_64-local-staging/staging ~/macos-aarch64-local-staging/staging ~/macos-x86_64-local-staging/staging ~/centos7-aarch64-local-staging/staging ~/debian7-x86_64-local-staging/staging ~/centos6-x86_64-local-staging/staging ~/uber-local-staging/staging
451+ run : bash ./.github/scripts/local_staging_merge_release.sh ~/local-staging ~/windows-x86_64-local-staging ~/macos-aarch64-local-staging ~/macos-x86_64-local-staging ~/centos7-aarch64-local-staging ~/debian7-x86_64-local-staging ~/centos6-x86_64-local-staging ~/uber-local-staging
452+
453+ - name : Create bundle
454+ working-directory : ./prepare-release-workspace/
455+ run : bash ./.github/scripts/bundle_create.sh ~/central-bundle.zip ~/local-staging/
452456
453- - name : Deploy local staged artifacts
457+ - name : Upload bundle to maven central
454458 working-directory : ./prepare-release-workspace/
455- # If we don't want to close the repository we can add -DskipStagingRepositoryClose=true
456- run : ./mvnw -B --file pom.xml org.sonatype.plugins:nexus-staging-maven-plugin:deploy-staged -DnexusUrl=https://oss.sonatype.org -DserverId=sonatype-nexus-staging -DaltStagingDirectory=$HOME/local-staging -DskipStagingRepositoryClose=true
459+ run : bash ./.github/scripts/bundle_upload.sh ~/central-bundle.zip ${{ secrets.MAVEN_CENTRAL_USERNAME }} ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
457460
458461 - name : Rollback release on failure
459462 working-directory : ./prepare-release-workspace/
0 commit comments