Kamilski81
Kamilski81

Reputation: 15127

Why is my production environment pulling in development gems in Rails?

I'm not sure why this is happening, any clue???

$ echo $RAILS_ENV
production
----
$ bundle | grep debug
Using ruby-debug-base19 (0.11.25) 
Using ruby-debug-base19x (0.11.29) 
Using ruby-debug19 (0.11.6) 
----
$ gem list | grep debug
ruby-debug-base19 (0.11.25)
ruby-debug-base19x (0.11.29)
ruby-debug19 (0.11.6)

Gemfile:

group :development do
  gem "mailcatcher", "~> 0.5.5"
  gem 'capistrano',           '~> 2.9.0'
  gem 'capistrano-ext',       '1.2.1'
  gem 'ruby-debug19', :require => 'ruby-debug'
  gem 'ruby-debug-base19x'
  gem 'ruby-debug-base19'
end

Upvotes: 0

Views: 182

Answers (1)

iltempo
iltempo

Reputation: 16012

Make sure you are deploying by using

bundle install --without development,test

Bundler is installing all gems that are not is those groups in your Gemfile.

If you are using capistrano you can specify in your deploy.rb

set :bundle_without, [:development, :test]

Upvotes: 4

Related Questions