Missing database.yml file in a project using Rails 3
We'll I actually encountered this problem with missing database.yml file in a project using Rails 3 and my solution was to add a new file in config folder that is the database.yml
Here's how:
1. Understand the Error. In that first line, you can see this error
/Users/honeylyn/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/application/configuration.rb:115:in `read': No such file or directory - /Users/honeylyn/WebApps/honee-adakite/config/database.yml (Errno::ENOENT)
So you know that your database.yml is missing as it said "No such file or directory'
2. Go to your text-editor and look for the config folder.
You might ask what should be added in the database.yml file
Here's an example of what I added on my database.yml file since I'm using sqlite3:
# SQLite version 3.x # gem install sqlite3 # # Ensure the SQLite 3 gem is defined in your Gemfile # gem 'sqlite3' development: adapter: sqlite3 database: db/development.sqlite3 pool: 5 timeout: 5000 # 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: adapter: sqlite3 database: db/test.sqlite3 pool: 5 timeout: 5000 production: adapter: sqlite3 database: db/production.sqlite3 pool: 5 timeout: 5000

















