0.0
No commit activity in last 3 years
No release in over 3 years
A Rubygems remote source server that implements the core Rubygems web API (gem indicies, specs, push, and yank). Wins for local and private gem servers.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

 Project Readme

rubygems-source travis-ci

rubygems-source is a remote source server for Rubygems that implements the core Rubygems gem source web API.

Use it to host private or local dev gem servers.

Usage

Start yr server

Create a config.ru like this (there's an example config.ru.example included):

require "rubygems-source"       

Rubygems::Source::App.public_folder = "/var/gems/" # or wherever
run Rubygems::Source::App

And rack up the config.ru with passenger, thin, unicorn etc.

Ensure public_folder is writeable by the server user.

Adapt config.ru to install Rack middleware if you need HTTP authentication etc.

Configure yr rubygems

You need to configure rubygems wherever you want to use your new source server.

If you use Bundler, add it to the top of your Gemfiles:

source "http://gems.example.com"

To make the new source server available to your entire Rubygems installation:

$ gem sources --add http://gems.example.com

You can also add the new source to your .gemrcs directly.

You can now find and install gems from the new source server.

$ gem list -r mygem
$ gem install mygem

You can also push gems to the server. Be sure to specify the host.

$ gem push pkg/mygem-0.0.2.gem --host http://gems.example.com     

Check out rubygems-source-cli for some patches to gem yank and gem push so they work better with non-Rubygems.org sources.

Requirements

  • Rubygems

Install

  • gem install rubygems-source

or add it to your Gemfile:

  • gem "rubygems-source"

Development

Pull requests are very welcome! Make sure your patches are well tested. Please create a topic branch for every separate change you make.

Roadmap

  • authenticate gem admin actions via API key
  • implement gem dependency resolver
  • show HTML list of gems/versions/links to rdoc at /
  • remove Sintra dependency in favour of plain Rack for smaller footprint
  • support legacy index/spec format?

Testing

$ rake

Related projects

Author

Dave Nolan