diff --git a/.github/workflows/release-snapshot.yml b/.github/workflows/release-snapshot.yml index f154ab8227..f840002969 100644 --- a/.github/workflows/release-snapshot.yml +++ b/.github/workflows/release-snapshot.yml @@ -49,7 +49,7 @@ jobs: - name: Release run: ./gradlew --build-cache publishToSonatype env: - CTP_OSS_USER: ${{ secrets.OSS_USER }} - CTP_OSS_SECRET: ${{ secrets.OSS_SECRET }} + SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} + SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} - run: rm -rf ~/.gradle/gradle.properties diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e5fe2aabf0..03d45be926 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -39,8 +39,8 @@ jobs: - run: ./gradlew -Pversion=$REF_NAME clean test javadoc publishToSonatype closeAndReleaseSonatypeStagingRepository env: REF_NAME: ${{ github.ref_name }} - CTP_OSS_USER: ${{ secrets.OSS_USER }} - CTP_OSS_SECRET: ${{ secrets.OSS_SECRET }} + SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} + SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} diff --git a/gradle-scripts/publishing.gradle b/gradle-scripts/publishing.gradle index ea2fc8b3c6..bd6c8879be 100644 --- a/gradle-scripts/publishing.gradle +++ b/gradle-scripts/publishing.gradle @@ -21,8 +21,10 @@ def excludeProjects = [ nexusPublishing { repositories { sonatype { - username = System.getenv('CTP_OSS_USER') - password = System.getenv('CTP_OSS_SECRET') + nexusUrl.set(uri("https://ossrh-staging-api.central.sonatype.com/service/local/")) + snapshotRepositoryUrl.set(uri("https://central.sonatype.com/repository/maven-snapshots/")) + username = System.getenv('SONATYPE_USERNAME') + password = System.getenv('SONATYPE_PASSWORD') } } }