首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Rails Composer不适用于Windows。SSL错误

Rails Composer不适用于Windows。SSL错误
EN

Stack Overflow用户
提问于 2013-10-17 14:47:11
回答 1查看 679关注 0票数 1

我有Ruby2.0和Rails 4.0的RailsInstaller。我创建了一个应用程序:

代码语言:javascript
复制
$ rails new myapp -m https://raw.github.com/RailsApps/rails-composer/master/composer.rb

然后我得到了这个

代码语言:javascript
复制
apply  https://raw.github.com/RailsApps/rails-composer/master/composer.rb
C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/net/http.rb:918:in `connect': SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (OpenSSL::SSL::SSLError)
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/net/http.rb:918:in `block in connect'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/timeout.rb:52:in `timeout'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/net/http.rb:918:in `connect'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/net/http.rb:862:in `do_start'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/net/http.rb:851:in `start'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:313:in `open_http'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:708:in `buffer_open'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:210:in `block in open_loop'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:208:in `catch'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:208:in `open_loop'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:149:in `open_uri'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:688:in `open'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/2.0.0/open-uri.rb:34:in `open'
        from C:/RailsInstaller/Ruby2.0.0/lib/ruby/gems/2.0.0/gems/thor-0.18.1/lib/thor/actions.rb:216:in `apply'

这是什么?非常感谢!

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2013-10-17 15:01:57

从cacert.pem下载这里文件。将此文件保存到C:\RailsInstaller\cacert.pem。

现在,通过设置SSL_CERT_FILE使ruby知道您的证书颁发机构包。若要在当前命令提示符会话中设置此设置,请键入:

代码语言:javascript
复制
  $  set SSL_CERT_FILE=C:\RailsInstaller\cacert.pem

就这样。工作得很好!

票数 3
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/19429981

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档