Ruby on Rails 初心者です。
Windows 8
ruby Ruby 2.3.3p222 (2016-11-21 revision 56859) [x64-mingw32]
Rails 5.0.1
書籍やネットを見ながら学習を進めています。
書籍やネットの情報によると、config/database.ymlの中に
development(開発用)、test(テスト用)、production(本番用)の3つ
出来るそうですが、私の環境では「default」というのだけしか設定?準備されません。
これは何故でしょうか?
開発用で作業したいのですが・・・
database.ymlの内容
database.yml
1# SQLite version 3.x 2# gem install sqlite3 3# 4# Ensure the SQLite 3 gem is defined in your Gemfile 5# gem 'sqlite3' 6# 7default: &default 8 adapter: sqlite3 9 pool: 5 10 timeout: 5000 11 12development: 13 <<: *default 14 database: db/development.sqlite3 15 16# Warning: The database defined as "test" will be erased and 17# re-generated from your development database when you run "rake". 18# Do not set this db to the same as development or production. 19test: 20 <<: *default 21 database: db/test.sqlite3 22 23production: 24 <<: *default 25 database: db/production.sqlite3 26
回答2件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。