Chef::Provider::Package::Rubygems - Ruby Gems Source


#1

Hi Everyone,

I want to question the functionality of installing a Gem from an additional source.

By default, the Ruby Gem provider is adding the ‘http:/rubygems.org’ source along with any user specified source (as long as it does not end in .gem).

I use my own local gem server (geminabox), with no access to the outside world, prohibiting access to http://rubygems.org.

Now the next part is controversial…

Ruby Gems throws a timeout error because it cannot connect to both sources, failing to install the gem from my local gem server which exists.

Yes, that is a Ruby Gem issue. However, I question whether the provider should be appending the ‘rubygems.org’ source in the first place.

In my opinion, I would suggest using the user specified gem source only, or the gem sources from the host machine.

Open for other peoples suggestions, this is my first post!

Thanks,

Ben


#2

yep:

https://tickets.opscode.com/browse/CHEF-4539

On Mon Apr 28 14:13:07 2014, Ben McRae wrote:

Hi Everyone,

I want to question the functionality of installing a Gem from an
additional source.

By default, the Ruby Gem provider is adding the ‘http:/rubygems.org
http://rubygems.org’ source along with any user specified source (as
long as it does not end in .gem).

https://github.com/opscode/chef/blob/master/lib/chef/provider/package/rubygems.rb#L535

I use my own local gem server (geminabox), with no access to the
outside world, prohibiting access to http://rubygems.org.

Now the next part is controversial…

Ruby Gems throws a timeout error because it cannot connect to both
sources, failing to install the gem from my local gem server which exists.

Yes, that is a Ruby Gem issue. However, I question whether the
provider should be appending the ‘rubygems.org http://rubygems.org
source in the first place.

In my opinion, I would suggest using the user specified gem source
only, or the gem sources from the host machine.

Open for other peoples suggestions, this is my first post!

Thanks,

Ben