I'd go with your last approach. In our case we never use the staging env, only production. So the line can be:
config.stretches = Rails.env.production? ? 10 : 1