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

Publish snapshots to oss.jfrog.org #365

Closed
mojavelinux opened this issue Jul 24, 2015 · 20 comments
Closed

Publish snapshots to oss.jfrog.org #365

mojavelinux opened this issue Jul 24, 2015 · 20 comments

Comments

@mojavelinux
Copy link
Member

Publish snapshots to oss.jfrog.org to allow users to test the lastest version without having to build it locally.

@robertpanzer
Copy link
Member

Sent request to host asciidoctorj on oss.jfrog.og with the groupid org.asciidoctor.

@mojavelinux
Copy link
Member Author

👍

@robertpanzer
Copy link
Member

Snapshots for 1.6.0 can now be published with a6b7dd7.
First snapshots, even for the distribution, are available.

@abelsromero
Copy link
Member

Maybe a silly question, but anyone can publish snapshots? Or is there some pre-requeriment configuration?

@robertpanzer
Copy link
Member

There's no silly questions!
I think it should be possible for everyone who is a member of the asciidoctor organization on Bintray.

@abelsromero
Copy link
Member

Confirmed!
Only after setting bintrayUsername and bintrayApiKey I could publish the snapshots.

I guess the next step is having nightly builds.

@robertpanzer
Copy link
Member

Yes! Same as when publishing to bintray.
(I should've mentioned that in the readme, sorry!)

I think for continuous snapshots only two problems remain:

  1. When publishing from Travis which of the 4 environments should publish the snapshot?
  2. Where and how to store the credentials in a secure manner?

Am 28.07.2015 um 18:18 schrieb Abel Salgado Romero notifications@github.com:

Confirmed!
Only after setting bintrayUsername and bintrayApiKey I could publish the snapshots.

I guess the next step is having nightly builds.


Reply to this email directly or view it on GitHub.

@mojavelinux
Copy link
Member Author

Where and how to store the credentials in a secure manner?

Secure environment variables. See http://docs.travis-ci.com/user/environment-variables/#Encrypted-Variables

@robertpanzer
Copy link
Member

Can we create a technical user for this?
I'd prefer to not put my personal credentials in there, in particular as the "Publisher" is also available in the build infos:)
The information about the encryption is a bit scarce and the RSA key has only a strength of 1024 Bit, but I think for that purpose it is generally ok.
(Would be fine though if we could restrict that user to only publish snapshots and not publish releases to jcenter.)

@robertpanzer
Copy link
Member

You see, I am little picky about security ;-)

@abelsromero
Copy link
Member

I'd prefer to not put my personal credentials in there, in particular as the "Publisher" is also available in the build infos:)

I agree with that, I would do the same :P

A part form security, is it possible in travis to trigger the build periodically? I've seen some third-party services (e.e. http://traviscron.pythonanywhere.com/) but it is not in Travis itself.

@mojavelinux
Copy link
Member Author

I'd prefer to not put my personal credentials in there, in particular as the "Publisher" is also available in the build infos:)

I agree with that, I would do the same :P

I "third" that.

In fact, we do have "asciidoctor-docbot", who is our little bot helper. We can use it to automation things. The bot already has an account on GitHub (https://github.com/asciidoctor-docbot). Does it need an account at bintray?

@robertpanzer robertpanzer reopened this Jul 29, 2015
@robertpanzer
Copy link
Member

Does it need an account at bintray?

I think so. I was also added separately to the GitHub Asciidoctor organization and the Bintray organization.
Seems to be two different groups that are not coupled in any way. (I even have a different user name on bintray than on Github.)

@mojavelinux
Copy link
Member Author

Super! I'll get that up asap and send you the credentials.

@robertpanzer
Copy link
Member

👍

@robertpanzer
Copy link
Member

Regarding nightly builds or builds respectively that are not event triggered only make sense if we package an Asciidoctor snapshot.
Otherwise we should;-) get the same builds as longs as there are no changes to the sources in AsciidoctorJ.

Another point we have to look at is to publish snapshots only for those builds when dedicated branches in the asciidoctor/asciidoctorj repo change, not when a PR is opened or gets new commits.

@mojavelinux
Copy link
Member Author

Credentials sent.

I think we only need to publish when a commit hits the branch on which the snapshot is based. I'm not sure if we want snapshots for 1.5.x. For now, I'd rather just stick with 1.6.0 snapshots until we iron out the workflow for other branch post-1.6.0.

not when a PR is opened or gets new commits.

Travis has an environment variable for this. See the docs.

@robertpanzer
Copy link
Member

Snapshots are now published automatically from the oraclejdk8 environment on travis.
After a successful build on that environment ./gradlew clean build artifactoryPublish -x test is called.
Artifacts are published by the user asciidoctor-docbot.
Therefore the .travis.yml now sets the environment variables BINTRAY_USER and BINTRAY_KEY.
These are encrypted via travis encrypt -r asciidoc/asciidoctorj BINTRAY_USER=asciidoctor-docbot BINTRAY_KEY=<APIKEY>

@mojavelinux
Copy link
Member Author

Great work @robertpanzer!!! Your SysOps skills are strong and shining.

@robertpanzer
Copy link
Member

🍻

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

No branches or pull requests

3 participants