0

I need to install ruby, gem, Ruby on Rails and some other gems in a system which has no access to internet as of now. However, I will be given access for few really required urls for few days. I need to raise a firewall requests for those URLs. Please help with the list of urls.

Sachin Dangol
  • 504
  • 5
  • 13

3 Answers3

1

Rather than trying to whitelist individual domains (or worse, documents/pages/urls) you could use a VPN or HTTP proxy and whitelist it. This would allow you to fetch necessary files, updates, gems, etc. without identifying them in advance.

coreyward
  • 77,547
  • 20
  • 137
  • 166
1

RubyGems.org is the Ruby community’s gem hosting service.

If a gem can be installed using 'gem install' command that means the gem is available on RubyGems.org. Almost all the useful gems are available here.

In case you want some specific gem that isn't published on RubyGems.org, then you have to whitelist the URL to github repository of that particular gem.

For example a gem 'xyz' if not available at RubyGems.org then whitelist

https://github.com/user_name/xyz.git for HTTPS

OR

git@github.com:user_name/xyz.git

for SSH.

For Ruby, Rails and dependencies installation you need to use these urls:

ruby-lang.org => if you plan to install ruby using source

rvm.io => to install using rvm or better option is to use rbenv.

nodesource.com => for installing node.js

and rest depends on your OS. If using debian or Ubuntu you have to whitelist:

packages.debian.org and packages.ubuntu.com

Most of the packages/gems/dependencies can be installed if you get SSH access to github.com. Or you can try installing the required packages to a system with full internet access and then exporting them to the desired system.

You can use Http proxies if the people behind Firewall aren't smart enough. Or VPN is the only way out as suggested by #coreyward

Community
  • 1
  • 1
0

A lot of the gems you can find here. However, you can have gems hosted locally to an organization or you can also install them from their github repo.

However, once you install the gems, they are stored locally in your system and you can access the gems from there without an internet connection. When you do a bundle install, first your local gems are searched (unless specified otherwise) for the gem and if it does not find there it looks for it in the remote location. Check out this answer to know where the gems are usually stored locally. Where does bundler store gems?

Community
  • 1
  • 1
slal
  • 2,657
  • 18
  • 29