1

I have a Continuous Integration / Continuous Deployment scenario where I want my build script to push a ruby gem directly from a public Build Server (teamcity.codebetter.com) to RubyGems.org.

The problem is: How can I specify my credentials? On my local machine I have them under ~/.gem/credentials and everything works fine but how can I tell the build server to push my gem?

Thanks and best regards, Steffen Forkmann

forki23
  • 2,784
  • 1
  • 28
  • 42

2 Answers2

1

You could just use the API itself to push the gems. See the POST /api/v1/gems endpoint: http://rubygems.org/pages/api_docs

qrush
  • 1,003
  • 10
  • 11
0

I would guess if you manually pushed once from the continuous integration box as the user who runs the CI software it could push in the future.

Jason Noble
  • 3,756
  • 19
  • 21
  • Yes. That's true, but as I said it is a public CI server. Adding the public CI user as a gem owner to my gem means every other project could possibly "update" my gem. – forki23 Aug 06 '10 at 10:50
  • 1
    You could look at setting up a callback URL on a separate server, then have your build process access that URL on successful build. – Jason Noble Aug 06 '10 at 13:37