From ef655ce94972af2cd6c8ce67c48f29742e454da0 Mon Sep 17 00:00:00 2001 From: Madhura Bhave Date: Mon, 15 Oct 2018 15:14:08 -0700 Subject: [PATCH] Update sonatype credentials in sync-to-maven-central job Closes gh-14454 --- ci/pipeline.yml | 4 ++-- ci/scripts/sync-to-maven-central.sh | 2 +- ci/tasks/sync-to-maven-central.yml | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ci/pipeline.yml b/ci/pipeline.yml index 9a3bfe3e95..43180d1c9d 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -465,8 +465,8 @@ jobs: params: BINTRAY_USERNAME: ((bintray-username)) BINTRAY_PASSWORD: ((bintray-password)) - SONATYPE_USERNAME: ((sonatype-username)) - SONATYPE_PASSWORD: ((sonatype-password)) + SONATYPE_USER_TOKEN: ((sonatype-user-token)) + SONATYPE_PASSWORD_TOKEN: ((sonatype-user-token-password)) BINTRAY_SUBJECT: ((bintray-subject)) BINTRAY_REPO: ((bintray-repo)) groups: diff --git a/ci/scripts/sync-to-maven-central.sh b/ci/scripts/sync-to-maven-central.sh index d644c3bf9c..073c73bb5d 100755 --- a/ci/scripts/sync-to-maven-central.sh +++ b/ci/scripts/sync-to-maven-central.sh @@ -12,7 +12,7 @@ echo "Syncing ${buildName}/${buildNumber} to Maven Central" --connect-timeout 240 \ --max-time 2700 \ -u ${BINTRAY_USERNAME}:${BINTRAY_PASSWORD} \ - -H "Content-Type: application/json" -d "{\"username\": \"${SONATYPE_USERNAME}\", \"password\": \"${SONATYPE_PASSWORD}\"}" \ + -H "Content-Type: application/json" -d "{\"username\": \"${SONATYPE_USER_TOKEN}\", \"password\": \"${SONATYPE_PASSWORD_TOKEN}\"}" \ -f \ -X \ POST "https://api.bintray.com/maven_central_sync/${BINTRAY_SUBJECT}/${BINTRAY_REPO}/${groupId}/versions/${version}" > /dev/null || { echo "Failed to sync" >&2; exit 1; } diff --git a/ci/tasks/sync-to-maven-central.yml b/ci/tasks/sync-to-maven-central.yml index f61d022ce5..51235b0a97 100644 --- a/ci/tasks/sync-to-maven-central.yml +++ b/ci/tasks/sync-to-maven-central.yml @@ -8,7 +8,7 @@ params: BINTRAY_SUBJECT: BINTRAY_USERNAME: BINTRAY_PASSWORD: - SONATYPE_USERNAME: - SONATYPE_PASSWORD: + SONATYPE_USER_TOKEN: + SONATYPE_PASSWORD_TOKEN: run: path: git-repo/ci/scripts/sync-to-maven-central.sh