ruby - bundle install / update太慢了 [英] ruby - bundle install/update too slow

查看:474
本文介绍了ruby - bundle install / update太慢了的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚在虚拟机中运行的虚拟ubuntu 12.04 32bit上安装了RVM,Ruby,Rails等。现在我遇到了我的第一个rails项目 bundle install bundle update 需要很长时间的问题。即使我使用rails创建一个新项目(其中包括 bundle install )。



我只使用标准宝石:

  source'https: //rubygems.org'

gem'rails','3.2.12'

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

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


#默认情况下,Gems仅用于资产,并且在生产环境中不需要
#。
group:assets do
gem'sass-rails','3.2.5'
gem'coffee-rails','3.2.2'

#参见https://github.com/sstephenson/execjs#readme获得更多支持的运行时
#gem'therubyracer',:platforms => :ruby

gem'uglifier','1.2.3'
end

gem'jquery-rails','2.0.2'

我尝试了没有任何宝石的bundle安装,但是 gem'rails','3.2.12' code>。之后,我再次在我的gemfile中键入 bundle install 和所有宝石。花了我10分钟来检查依赖关系。 --verbose的输出结合了 HTTP成功 HTTP重定向



Rails版本:Rails 3.2.12

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



Rvm:rvm 1.18.18

捆绑版本:Bundler版本1.3.2

我已经搜索了一个解决方案,但没有任何帮助。 更改 https code>到 http 在我的 Gemfile 中发挥了神奇的作用。在我必须使用 rails创建项目之前新的APP --skip-bundle



我想在此警告说,通过http使用https有一个安全目的。首先尝试本主题中提到的其他答案。


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.

解决方案

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

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

这篇关于ruby - bundle install / update太慢了的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆