rake db 创建中止
rake db create aborted
我一直在尝试使用 Ruby 2.3.8 修复我的项目,我正在使用 rvm 安装 Ruby 2.3.8 但需要额外的工作才能将其安装到我的 mac 因为 2.3.8
需要无法用 openssl 1.1
解析。所以我需要找到如何安装 openssl 1.0
因为 Homebrew 删除了 openssl 1.0
所以它需要额外的研究来修复它。
在我的项目中,我使用 MySQL 5.7 并安装 MySQL 5.7 我需要再次安装 OpenSSL 1.1,因此它会自动安装 OpenSSL 1.1
当我去我的项目做rake db:create
时,我得到了这样的错误:
rake aborted!
LoadError: library not found for class Digest::SHA1 -- digest/sha1
/Users/hoomacbuk/Documents/mekari/quickbook/config/boot.rb:4:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/config/application.rb:1:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/Rakefile:4:in `<top (required)>'
/Users/hoomacbuk/.rvm/gems/ruby-2.3.8/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
Caused by:
LoadError: dlopen(/Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle, 9): Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib
Referenced from: /Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle
Reason: image not found - /Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle
/Users/hoomacbuk/Documents/mekari/quickbook/config/boot.rb:4:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/config/application.rb:1:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/Rakefile:4:in `<top (required)>'
/Users/hoomacbuk/.rvm/gems/ruby-2.3.8/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
当我 运行ning bin/rake db:create
我又遇到了这个错误:
/Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/digest.rb:16:in `const_missing': library not found for class Digest::SHA1 -- digest/sha1 (LoadError)
我怎样才能得到 Ruby 2.3.x 到 运行?我
您的 ruby 版本似乎有问题。
卸载当前版本并重新安装相同版本,然后重试。
rvm uninstall 2.3.8
然后是
rvm install 2.3.8
我一直在尝试使用 Ruby 2.3.8 修复我的项目,我正在使用 rvm 安装 Ruby 2.3.8 但需要额外的工作才能将其安装到我的 mac 因为 2.3.8
需要无法用 openssl 1.1
解析。所以我需要找到如何安装 openssl 1.0
因为 Homebrew 删除了 openssl 1.0
所以它需要额外的研究来修复它。
在我的项目中,我使用 MySQL 5.7 并安装 MySQL 5.7 我需要再次安装 OpenSSL 1.1,因此它会自动安装 OpenSSL 1.1
当我去我的项目做rake db:create
时,我得到了这样的错误:
rake aborted!
LoadError: library not found for class Digest::SHA1 -- digest/sha1
/Users/hoomacbuk/Documents/mekari/quickbook/config/boot.rb:4:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/config/application.rb:1:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/Rakefile:4:in `<top (required)>'
/Users/hoomacbuk/.rvm/gems/ruby-2.3.8/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
Caused by:
LoadError: dlopen(/Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle, 9): Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib
Referenced from: /Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle
Reason: image not found - /Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/x86_64-darwin18/digest/sha1.bundle
/Users/hoomacbuk/Documents/mekari/quickbook/config/boot.rb:4:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/config/application.rb:1:in `<top (required)>'
/Users/hoomacbuk/Documents/mekari/quickbook/Rakefile:4:in `<top (required)>'
/Users/hoomacbuk/.rvm/gems/ruby-2.3.8/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
当我 运行ning bin/rake db:create
我又遇到了这个错误:
/Users/hoomacbuk/.rvm/rubies/ruby-2.3.8/lib/ruby/2.3.0/digest.rb:16:in `const_missing': library not found for class Digest::SHA1 -- digest/sha1 (LoadError)
我怎样才能得到 Ruby 2.3.x 到 运行?我
您的 ruby 版本似乎有问题。
卸载当前版本并重新安装相同版本,然后重试。
rvm uninstall 2.3.8
然后是
rvm install 2.3.8