[英]Trying to install gems needed to run the twitter Bootstrap gem - getting error while running bundle
我有一个常规的Rails 4应用程序,我正在尝试将其Twitter引导框架合并到其中。
我的gemfile的相关部分如下所示:
#Gems used only for assets and not required in production environments by default
group :assets do
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
gem "therubyracer", :require => 'v8'
gem "less-rails", "~> 2.4.2"
# Use SCSS for stylesheets
gem 'sass-rails', '~> 4.0.0'
# Use CoffeeScript for .js.coffee assets and views
gem 'coffee-rails', '~> 4.0.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
gem "twitter-bootstrap-rails", "~> 2.2.8"
end
在终端上运行bundle命令时,出现以下错误:
> bundle
Fetching gem metadata from https://rubygems.org/...........
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Using rake (10.1.0)
Using i18n (0.6.5)
Using minitest (4.7.5)
Using multi_json (1.8.0)
Using atomic (1.1.14)
Using thread_safe (0.1.3)
Using tzinfo (0.3.37)
Using activesupport (4.0.0)
Using builder (3.1.4)
Using erubis (2.7.0)
Using rack (1.5.2)
Using rack-test (0.6.2)
Using actionpack (4.0.0)
Using mime-types (1.25)
Using polyglot (0.3.3)
Using treetop (1.4.15)
Using mail (2.5.4)
Using actionmailer (4.0.0)
Using activemodel (4.0.0)
Using activerecord-deprecated_finders (1.0.3)
Using arel (4.0.0)
Using activerecord (4.0.0)
Using annotate (2.5.0)
Using bundler (1.3.5)
Using coffee-script-source (1.6.3)
Using execjs (2.0.2)
Using coffee-script (2.2.0)
Using thor (0.18.1)
Using railties (4.0.0)
Using coffee-rails (4.0.0)
Gem::RemoteFetcher::FetchError: SSL_connect returned=1 errno=0 state=SSLv3 read server
certificate B: certificate verify failed
(https://s3.amazonaws.com/production.s3.rubygems.org/gems/commonjs-0.2.7.gem)
An error occurred while installing commonjs (0.2.7), and Bundler cannot continue.
Make sure that `gem install commonjs -v '0.2.7'` succeeds before bundling.
我究竟做错了什么? 谢谢
这是Mac上的常见问题(对我来说确实如此)。 尝试更新openssl:
brew update
brew install openssl
有时更新符号链接和证书也很有用:
brew link openssl --force
brew install curl-ca-bundle
如果这没有帮助,并且您正在使用RVM,请尝试更新rvm的证书:
rvm osx-ssl-certs update all
希望这可以帮助!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.