gemfile に以下を追記します。
gem 'mysql2'
追記後 bundle install を実行します。
bundle install
config/database.yml もadapter をmysql2
に変更し、プロジェクト詳細ページに記載されているデータベースの各種項目を設定します。
キャプチャの赤枠の箇所を参考にしてください。
config/database.yml
# SQLite version 3.x
# gem install sqlite3
#
# Ensure the SQLite 3 gem is defined in your Gemfile
# gem 'sqlite3'
#
default: &default
adapter: mysql2
pool: 5
timeout: 5000
username: 任意のユーザ名
password: 任意のパスワード
development:
<<: *default
database: rails_development
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
test:
<<: *default
database: rails_test
production:
<<: *default
database: DB名
username: ユーザ名
password: プロジェクト作成時に入力したDBパスワード
host: ホスト名
以上で終了になります。
この設定でgit pushすると、push毎に以下を実行します。
rake db:create
rake db:migrate
rake assets:precompile