Skip to content

Commit 1dbdbbc

Browse files
docs: Using Sonatype User Access Token for Publishing to Maven
In case anyone else gets '401' error trying to publish to Sonatype Central using username+password - it seems this is no longer allowed. TODO: 1. create a user access token. (The token consists of two parts) 2. use part1 as 'username' and part2 as 'password'! Wasn't an easy find. References: - https://support.sonatype.com/hc/en-us/articles/360049469534-401-Content-access-is-protected-by-token-when-accessing-repositories - https://help.sonatype.com/en/user-tokens.html#using-your-user-token-for-repository-authentication_body
1 parent 385c6a3 commit 1dbdbbc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,8 @@ The GH actions job [callable.publish-sonatype.yml](.github/workflows/callable.pu
111111

112112
| Secret name | Value |
113113
|--------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
114-
| `OSSRH_USERNAME` | The username of your OSSRH account. |
115-
| `OSSRH_PASSWORD` | The password of your OSSRH account. |
114+
| `OSSRH_USERNAME` | ~The username of your OSSRH account.~ The first part of your OSSRH (Sonatype) user access token. |
115+
| `OSSRH_PASSWORD` | ~The password of your OSSRH account.~ The second part of your OSSRH (Sonatype) user access token. |
116116
| `GPG_SIGNING_KEY` | The GPG private key to sign your artifacts (in ascii-armored format). You can obtain it with `gpg --armor --export-secret-keys <your@email.here>` or you can create one key online on [pgpkeygen.com](https://pgpkeygen.com). |
117117
| `GPG_SIGNING_PASSPHRASE` | The passphrase for unlocking the secret key. (you picked it when creating the key). |
118118

0 commit comments

Comments
 (0)