ruby - bundle install/update too slow

Robin Wieruch picture Robin Wieruch · Mar 11, 2013 · Viewed 23.4k times · Source

I just installed RVM, Ruby, Rails etc. on my virtual ubuntu 12.04 32bit running in a virtualbox. Now I encounter the problem that for my first rails project bundle install or bundle update takes very long time. Even when I create a new project with rails (which includes bundle install).

I use only the standard gems:

source 'https://rubygems.org'

gem 'rails', '3.2.12'

# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'

group :development do
  gem 'sqlite3', '1.3.5'
end


# Gems used only for assets and not required
# in production environments by default.
group :assets do
  gem 'sass-rails',   '3.2.5'
  gem 'coffee-rails', '3.2.2'

  # See https://github.com/sstephenson/execjs#readme for more supported runtimes
  # gem 'therubyracer', :platforms => :ruby

 gem 'uglifier', '1.2.3'
end

gem 'jquery-rails', '2.0.2'

I tried bundle install without any gems but gem 'rails', '3.2.12'. After that I typed again bundle install with all gems in my gemfile. It took me 10 minutes to check for dependencies. The output of --verbose is a mix of HTTP success and HTTP redirection.

Rails version: Rails 3.2.12

Ruby version: ruby 1.9.3p392 (2013-02-22 revision 39386)

Rvm: rvm 1.18.18

bundle version: Bundler version 1.3.2

I already searched fot a solution, but nothing helped.

Answer

Robin Wieruch picture Robin Wieruch · Apr 16, 2013

I want to warn: There is a security purpose for using https over http. Try at first the other answers mentioned in this thread.

Changing https to http in my Gemfile did the magic. Before I have to create the project with rails new APP --skip-bundle