Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 5th, 2012  |  syntax: None  |  size: 0.45 KB  |  hits: 35  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Configuring Grails application to use ClearDB/MySQL on Heroku
  2. dataSource {
  3.   pooled = true
  4.   driverClassName = "com.mysql.jdbc.Driver"
  5. }
  6.        
  7. production {        
  8.   dataSource {
  9.     dbCreate = "update"
  10.       uri = new URI(System.env.DATABASE_URL?:"mysql://99784530f103:934c2a0@server.cleardb.com/heroku_0ac7f6f45fa34")
  11.       url = "jdbc:mysql://"+uri.host+uri.path
  12.       username = uri.userInfo.split(":")[0]
  13.       password = uri.userInfo.split(":")[1]
  14.     }
  15. }