Reputation: 31
I built a rails app with sqlite3 in development. Now that i want to deploy to rackspace using mysql2 i want to know what changes i need. I don't want to transfer any data from development to production environment. My database.yml file looks like this:
# 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
Can you please tell me what changes I need in this file and what else do I have to do?
Upvotes: 2
Views: 620
Reputation: 557
You'll want your production database to look something like this:
production:
adapter: mysql2
encoding: utf8
database: name-of-your-mysql2-database-here
pool: 5
username: root
password: your_password
Upvotes: 1