Advertisement
Guest User

Untitled

a guest
May 16th, 2017
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. <% require "uri" %>
  2.  
  3. db_config: &db_config
  4. <% if ENV["DATABASE_URL"].present? %>
  5. <% uri = URI.parse(ENV["DATABASE_URL"]) if ENV["DATABASE_URL"].present? %>
  6. username: <%= uri.user %>
  7. password: <%= uri.password %>
  8. host: <%= uri.host %>
  9. <% else %>
  10. username: root
  11. password: 'MentorMate1'
  12. host: localhost
  13. <% end %>
  14. adapter: mysql2
  15. pool: 10
  16. timeout: 5000
  17. port: 3306
  18.  
  19. development:
  20. <<: *db_config
  21. database: twoforone_development
  22.  
  23. production:
  24. <<: *db_config
  25. database: twoforone_production
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement