美文网首页
Mac 安装rails 5.0.0 失败2019-03-19

Mac 安装rails 5.0.0 失败2019-03-19

作者: Zee_jin | 来源:发表于2019-03-19 18:59 被阅读0次

    ruby版本2.3.1

    rvm版本1.29.7

    电脑系统macOS Mojave 10.14.3

    bogon:~ jinzesu$ gem install rails -v 5.0.0

    ERROR:

    While executing gem … (Gem::Exception) Unable to require openssl, install OpenSSL and rebuild Ruby (preferred) or use non-HTTPS sources

    升级gem也是同样的错误 gem update --system

    bogon:~ jinzesu$ gem update --system

    ERROR:

    While executing gem … (Gem::Exception) Unable to require openssl, install OpenSSL and rebuild Ruby (preferred) or use non-HTTPS sources

    解决方案一:根据提示use non-HTTPS sources,使用http源 

    gem source -l

    gem source -r https://rubygems.org/ to remove 

    gem source -a http://rubygems.org/ to read 

    解决方案二:根据require openssl, install OpenSSL,

    升级Mac的:

    openssl brew install openssl rvm reinstall 2.3.0 --with-openssl-dir=brew --prefix openssl 

    相关文章

      网友评论

          本文标题:Mac 安装rails 5.0.0 失败2019-03-19

          本文链接:https://www.haomeiwen.com/subject/pewnmqtx.html