title: Bundler trying to install development gems in production
body: <p>When I try to deploy my Rails 5 application using Capistrano 3, it tries to install development gems even in staging. This is completely new behaviour and I have no idea where it's coming from (came in the middle of a bunch of commits to a controller, the deploy scripts or Gemfile weren't touched at all).</p>
  
  <p>The relevant lines of the <code>capistrano.log</code> are:</p>
  
  <pre><code>bash: line 1: 13108 Killed /path/to/my/app/rvm1scripts/rvm-auto.sh 2.4.0 bundle install --path /path/to/my/app/shared/bundle --without development test --deployment --quiet
  bundle stderr: Nothing written
  ** DEPLOY FAILED
  ** Refer to log/capistrano.log for details.
  </code></pre>
  
  <p>My capistrano.log can be found at <a href="https://gist.githubusercontent.com/mindseyeblind/914249e6de9e543866f24e956005934f/raw/0caff3e5fbbf11724bd43ea4e5700e6bbf391090/capistrano.log" rel="nofollow noreferrer">this gist</a>, but the gist of it is that it checks the bundle, which fails because the <code>group :development</code> gems aren't installed (obviously), and then tries to bundle install, which won't happen because they're in the development group. It's a weird, cyclical problem.</p>