2

I'm trying to push my local MySQL database to Heroku's ClearDB MySQL database. I've gone through a lot of errors of missing gems and such, and am getting stuck on one. I'm running:

heroku db:push mysql://user:password@localhost/db

It prompts me to enter the application name to confirm, and then I get a many errors looking like:

/usr/local/lib/site_ruby/1.8/rubygems.rb:779:in
`report_activate_error': Could not find RubyGem sequel (~> 3.20.0)
(Gem::LoadError)                                                 |
ETA:  --:--:--  from /usr/local/lib/site_ruby/1.8/rubygems.rb:214:in
`activate'  from /usr/local/lib/site_ruby/1.8/rubygems.rb:1082:in
`gem'   from /var/lib/gems/1.9.1/gems/taps-0.3.23/bin/schema:4

which is weird, because I have the Sequel gem installed, and the correct version (3.20.0). I've tried doing a complete reinstall of all my gems, and still have had no luck.

the Tin Man
  • 158,662
  • 42
  • 215
  • 303
jwegner
  • 7,043
  • 8
  • 34
  • 56

1 Answers1

3

I'm not sure you can use Heroku db:push for ClearDB - I simply did a local mySQL backup and then restored it directly onto the ClearDB instance - you can get the login credentials from the output of a heroku config in your application.

John Beynon
  • 37,398
  • 8
  • 88
  • 97
  • How did you restore it to the ClearDB instance? – jwegner Feb 09 '12 at 15:00
  • I used mysql tools connected to the clearDB instance to do the restore (in my case I was using sequelPro for Mac to export and import the database) – John Beynon Feb 09 '12 at 15:10
  • I was able to use push with the tap gem, but I needed to add sqlite3 to my development group in the Gemfile. I gave heroku the fully qualified resource path `heroku db:push mysql://root:@localhost/mydb` and made sure that I had the cleardb option selected and the config val set to the same as the cleardb config setting: `heroku config:add DATABASE_URL ...` – Jed Schneider Jul 13 '12 at 04:01
  • someone might want to check the cleardb's site for first hand information. http://www.cleardb.com/developers/connect/paas/heroku/python – milkersarac Sep 28 '12 at 09:52