Thanks for the responses everybody. I did not realize heroku defaulted to pg. I've got a couple of other little apps that I could swear use sqlite w/no problems, but they're both very simple & so maybe I was on pg all the time w/out noticing.
Thanks also for the tip on Bundler's grouping feature--that looks handy. Cheers, -Roy On Nov 28, 6:25 am, Raving Genius <[email protected]> wrote: > You seem to have a couple issues. Number one, Heroku is a read-only > file system. Sqlite3 stores the datbase in a single file in your app, > so unless you place the sqlite3 database in $APP_ROOT/tmp, it won't > work. Therefore just use the Heroku-provided Postgresql database. They > will ensure that your app has a proper database.yml file. > > Number two, you should be using Bundler's group feature to only > install the gems you need for each environment. In your case, I would > modify your Gemfile to be similair to the sample below. > > group :production do > gem 'pg' > end > > group :development, :test do > gem 'sqlite3-ruby', :require => '...' > end > > Be sure to run `bundle install` after changing your Gemfile. Then you > can tell Heroku to not install the :development or :test groups. I > don't recall the exact command, but you can find it at docs.heroku.com/ > bundler. Setting up your app like this will prevent Heroku from even > trying to install sqlite3. This setup also has the advantage of > creating a smaller slug size, which means faster deploys, among other > things. > > On Nov 27, 3:43 pm, Roy Pardee <[email protected]> wrote: > > > After posting I continued flailing about and eventually got it to work > > after migrating it to bamboo-ree-1.8.7 by commenting-out the line > > > gem 'sqlite3-ruby', :require => 'sqlite3' > > > in my Gemfile. This breaks the app for local use, but seems to fix it > > for heroku. > > > No clue whether that fix would have also fixed it on bamboo-mri-1.9.2. > > > Cheers, > > > -Roy > > -- You received this message because you are subscribed to the Google Groups "Heroku" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/heroku?hl=en.
