rake db:migrate error with mysql2 gem - Library not loaded: libssl.1.0.0.dylib

后端 未结 6 1928
死守一世寂寞
死守一世寂寞 2020-12-30 08:22

Getting the following error after running rake db:migrate

rake aborted!
LoadError: dlopen(/Users/scott/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/gems/mysql2-         


        
6条回答
  •  死守一世寂寞
    2020-12-30 08:39

    For users of rbenv:

     brew uninstall openssl
     brew install rbenv/tap/openssl@1.0
    
     gem uninstall mysql2
     gem install mysql2 -v '0.4.10' -- --with-opt-dir="$(brew --prefix rbenv/tap/openssl@1.0)"
    

提交回复
热议问题