Running a private gem server
I'm trying to run my own gem server of a specific folder--not the default gems folder for the machine. None of it is working.
First, I created a folder called /privateGems at the root of my server. Then I started gem server --dir=/privateGems
I tried to push a gem from my local machine to my server using info here:
http://help.rubygems.org/discussions/questions/14-running-our-own-g...
RUBYGEMS_HOST=http://my.server.com:8808 gem push pkg/mygem-0.1.0.gem
That asked for my credentials or something, so I bailed -- seems like it was still trying to push to the rubygems.org.
I resorted to copying all the source to the server, and doing a local install with the option -i /privateGems which at least got the gems installed where I wanted them for now.
Then I ran gem generate_index --directory=/privateGems -- that spit out a bunch of files in the /privateGems folder, but they're all pretty much empty. AFAICT none of my gems actually got indexed.
From my local machine, if I gem list --source=http://my.server.com:8808 I get a list of the gems in ruby's .../1.8/gems folder and not my /privateGems folder.
I've looked at about a half dozen blog, and read the gem help. One would infer that it should be a simple thing to accomplish.
So, I'm confused.
A) gem server isn't actually serving the folder I told it to
B) gem generate_index isn't indexing anything
C) I can't push anything to my private server
All-in-all none of the gem server stuff is working like I'm expecting it to, and I don't see what I've done wrong.
Any guidance here would be greatly appreciated.
-- gw
Comments are currently closed for this discussion. You can start a new one.
2 Posted by greg willits on 29 Oct, 2010 08:25 PM
bump.
or, is this not the right place to ask?
Support Staff 3 Posted by Nick Quaranto on 29 Oct, 2010 09:16 PM
Hi there,
The RubyGems built-in server does not support
gem push...that's through gemcutter only (http://github.com/rubygems/gemcutter)Usually what I recommend for internal installs is geminabox:
http://github.com/cwninja/geminabox/
Unless if you're hosting 1000's of gems, geminabox does the job nicely. Sorry about the delay here.
4 Posted by Greg Willits on 30 Oct, 2010 02:26 AM
So the whole built-in gem server thing is out of favor?
Giving geminabox a whirl, but it crashes trying to serve a gem.
Hopefully, the author will see my Issues post on github.
Thx for the reply.
-- gw
Support Staff 5 Posted by Nick Quaranto on 05 Nov, 2010 01:03 AM
I wouldn't say it's out of favor, it just doesn't respond to
gem push...only gemcutter does (and I believe geminabox). You could always regenerate the index (gem generate_index) and serve it up viagem server...but geminabox will probably be easier.Nick Quaranto closed this discussion on 05 Nov, 2010 01:03 AM.