Skip to content

Commit

Permalink
added DB config
Browse files Browse the repository at this point in the history
  • Loading branch information
mimani committed Mar 13, 2017
1 parent 3624801 commit 86f1e0c
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
README.rdoc# Add your own tasks in files placed in lib/tasks ending in .rake,
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.

require File.expand_path('../config/application', __FILE__)
Expand Down
34 changes: 34 additions & 0 deletions config/database.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
default: &default
adapter: 'mysql2'
username: 'root'
host: localhost
pool: 5
timeout: 5000

development:
<<: *default
database: backend_dev

test:
<<: *default
database: backend_test

staging:
adapter: 'mysql2'
database: <%= ENV['BACKEND_DB'] %>
username: <%= ENV['BACKEND_DB_USER'] %>
password: <%= ENV['BACKEND_DB_PASSWORD'] %>
host: <%= ENV['BACKEND_DB_HOST'] %>
pool: 5
timeout: 5000
reconnect: true

production:
adapter: 'mysql2'
database: <%= ENV['BACKEND_DB'] %>
username: <%= ENV['BACKEND_DB_USER'] %>
password: <%= ENV['BACKEND_DB_PASSWORD'] %>
host: <%= ENV['BACKEND_DB_HOST'] %>
pool: 10
timeout: 5000
reconnect: true

0 comments on commit 86f1e0c

Please sign in to comment.