ruby-on-rails-3 - 如何通过rails控制台加载openssl?

标签 ruby-on-rails-3 openssl

我使用了solution由 Radulescu 编写,用于使用 ruby​​ 1.9.3-p194 安装 openssl。然后,我试图要求 openssl,但我得到了错误的返回。为什么?

bla git:(master) rails c
Loading development environment (Rails 3.2.6)
[1] pry(main)> require 'openssl'
=> false

最佳答案

这仅仅意味着库已经被加载。如果您尝试输入 OpenSSL,您会看到它位于您的命名空间中。

相比之下,如果您尝试加载不存在的库,则会出现异常:

1.9.3p327 :003 > require 'does-not-exist'
LoadError: cannot load such file -- does-not-exist

关于ruby-on-rails-3 - 如何通过rails控制台加载openssl?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16170348/

相关文章:

ruby-on-rails - 如何在 rspec 测试中忽略 ApplicationController 中的 rescue_from?

mysql - 如何重新创建问题:Mysql2::Error:非法混合排序规则(latin1_swedish_ci,IMPLICIT)

ruby-on-rails - curl : (1) Protocol https not supported or disabled in libcurl

带有 OpenSSL v1 的 Python 3.5 MACOS Mojave

visual-c++ - 如何使用符号在 Release模式下构建 OpenSSL?

ruby - 无法与 ruby​​ 建立 https 连接

ruby-on-rails - 没有css文件的Rails脚手架?

ruby-on-rails - 参数不会传入子类

ruby-on-rails-3 - Gem 测试无法使用 url_for 找到路线

linux - 如何从源代码安装 nginx; : Got SSL_OP_MSIE_SSLV2_RSA_PADDING error