Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove bintray and deploy to maven central #521

Merged
merged 3 commits into from
May 4, 2021

Conversation

oryan-block
Copy link
Collaborator

Checklist

  • Pull requests follows the contribution guide
  • New or modified functionality is covered by tests

Description

Following the closure of bintray we need to replace it with direct deployment to maven central.
Unfortunately, following the rest of the org's gradle based config doesn't seem possible.
However, according to this guide and the documentation here this should work.

server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_KEY_CONTENTS }}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a bit of a guess but I assume we want the actual key here and not the key id or something else.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That variable is actually the file but base64 encoded. So it's the password encoded file that contains the key. See also the document I wrote in which I tried to explain that.

@oryan-block oryan-block requested review from oliemansm and vojtapol May 4, 2021 15:58
Copy link
Member

@oliemansm oliemansm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once you've made the changes you could run the action to try to publish the snapshot to the repo to prove it works. In these kind of cases that's the only way I know to really verify it works as intended.

I did the same thing for publishing an actual release to the staging repo but with close and release disabled. That way I could prove it was signing it correctly with gpg and uploading to nexus correctly. I then deleted those uploads manually afterwards, but at least I proved to myself the config was correct.

I'd advise a similar approach here.

pom.xml Outdated
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Our repo was created in the original one, so you should be using the same repository url as the one used in gradle.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would be oss.sonatype.org, right?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes

server-id: ossrh
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_KEY_CONTENTS }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That variable is actually the file but base64 encoded. So it's the password encoded file that contains the key. See also the document I wrote in which I tried to explain that.

pom.xml Outdated
<name>graphql-java-kickstart-graphql-java-tools</name>
<url>http://oss.jfrog.org/artifactory/oss-snapshot-local</url>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This url should be corrected too.

@oryan-block oryan-block requested a review from oliemansm May 4, 2021 17:19
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@oryan-block oryan-block merged commit 018096d into master May 4, 2021
@oryan-block oryan-block deleted the deploy-to-maven-central branch May 4, 2021 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants