gakkie プログラミング 備忘録

tech::expert(現tech camp) 45期

Cloud9 MySQLの設定でのトラブルと解決策

190708 16:54:17 url:https://qiita.com/emahiro/items/1a63d676be9fc4975759

$ bundle install
→error
An error occurred while installing mysql2 (0.5.2), and Bundler cannot continue.
Make sure that `gem install mysql2 -v '0.5.2' --source 'https://rubygems.org/'` succeeds before bundling.

$ git checkout -b test_miyagaki

$ gem install mysql2 -v '0.5.2'

→error
エラー内容
-----
mysql client is missing. You may need to 'apt-get install libmysqlclient-dev' or 'yum install mysql-devel', and try again.
-----
$ sudo yum install -y mysql-devel
$ bundle install
********************************************************************************
→成功