Skip to content

GitHub Maven Authentication #119679

Discussion options

You must be logged in to vote

Writing my notes up here in case they're useful for others. tl;dr is, instead of defining the header directly, do:

    <server>
      <id>github</id>
      <username>USERNAME</username>
      <password>ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxx</password>
    </server>

Replace ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxx with your token, but crucially you don't need to replace USERNAME with your actual username.

The longer explanation:

https://maven.pkg.github.com doesn't seem to be the direct URL for packages, it always returns a 302 (redirect) with a link to elsewhere that doesn't require authentication. It seems that redirected domain has recently changed - for older packages it seems to have typically been g…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by abdelmoez-guetat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working correctly API and Webhooks Discussions and conversations related to APIs or Webhooks
3 participants