Topic: bundler issue on production

Here is an extract of my gemfile

source 'http://rubygems.org'

gem 'rails', '3.0.1'
gem 'will_paginate', '~> 3.0.beta'
gem 'prawn'

group :development do
  gem "nifty-generators"
  gem 'web-app-theme', '>= 0.6.2'  
end

group :production do
  #todo sentia - this runs in dev
  # http://gembundler.com/man/gemfile.5.html
  # bundle install --without production
  gem 'mysql', '2.8.1'
end

The issue being that when I deploy to production server using capistrano I get this passenger error:

Error message:
    !!! Missing the mysql gem. Add it to your Gemfile: gem 'mysql', '2.8.1'

I have found that I can fix this error by running the following command on the production server:

bundle install --without development

I am ure I have something wrong and should not have to run this command - has anyone else experienced this?

Re: bundler issue on production

This is because mysql gem will be required in development environment also.
Without mysql gem, it will give you error

Missing the mysql gem.

Ritesh Kumar
http://rorguide.blogspot.com/