I get an error every time in my local environment so make a note of the solution
$ bundle install --path vendor/bundle ... Error statement ↓ An error occurred while installing mysql2 (0.5.3), and Bundler cannot continue.
$ bundle config --local build.mysql2 "--with-ldflags=-L/usr/local/opt/openssl/lib" $ bundle install --path vendor/bundle
When the above command is executed, the following line will be added to
.bundle / config
Will come to be.