Advertisement
Guest User

Untitled

a guest
Feb 12th, 2016
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. <%
  2. rake = File.split($0).last == 'rake'
  3. if rake
  4. begin
  5. STDOUT.puts "MySQL root Password:"
  6. password = STDIN.gets.strip.downcase
  7. end until password.length > 0
  8. end
  9. %>
  10.  
  11. # SQLite version 3.x
  12. # gem install sqlite3
  13. #
  14. # Ensure the SQLite 3 gem is defined in your Gemfile
  15. # gem 'sqlite3'
  16. development:
  17. adapter: mysql2
  18. database: app_development
  19. username: <%=rake ? 'root' : 'app_user' %>
  20. password: <%=rake ? password : 'app_password' %>
  21. pool: 5
  22. timeout: 5000
  23.  
  24. # Warning: The database defined as "test" will be erased and
  25. # re-generated from your development database when you run "rake".
  26. # Do not set this db to the same as development or production.
  27. test:
  28. adapter: mysql2
  29. database: app_test
  30. username: <%=rake ? 'root' : 'app_user' %>
  31. password: <%=rake ? password : 'app_password' %>
  32. pool: 5
  33. timeout: 5000
  34.  
  35. production:
  36. adapter: mysql2
  37. database: app_production
  38. username: <%=rake ? 'root' : 'app_user' %>
  39. password: <%=rake ? password : 'app_password' %>
  40. pool: 5
  41. timeout: 5000
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement