0

Of course you all heard about the latest security hole in Rails which requires some updates. I'm currently using version 2.3.14 of Rails and therefore tried updating to 2.3.15 (the patched version).

On my local machine the process really went the rails way. But after pushing the changes to Heroku and waiting for deployment, my app didn't start. It says in the logs

RubyGem version error: rails(2.3.15 not = 2.3.14)

No how could that happen? My Gemfile says

gem 'rails', '~> 2.3.15'

and my Gemfile.lock says

GEM
  specs:
    rails (2.3.15)

and, finally, Heroku tells me

Installing rails (2.3.15)

Really, where is the problem? Other people having this problem?

Solution

The answer by Charles included the solution, which is to update the RAILS_GEM_VERSION to 2.3.15 in config/environment.rb.

Important Notice

If you have the same troubles, please use one of the proposed solutions immediatly. There are already known cases of corrupted Rails apps!

Arne L.
  • 2,194
  • 19
  • 19
  • My guess is that another gem is dependent on rails 2.3.14, so you'll have to update one or more of those before pushing up. Of course, it seems like you'd be seeing this on your dev machine too. Are you testing your Procfile with `foreman start` on your local machine before pushing? – Austin Mullins Jan 12 '13 at 18:51

1 Answers1

0

It seems like you also need to do change RAILS_GEM_VERSION to 3.2.15 in environment.rb:

If you find yourself having to do the whole upgrading process over again, you can follow these steps:

  • Run your tests and make sure everything works
  • Open up a new branch through git (git checkout -b new_rails)
  • Change Rails 3.2.15 in your Gemfile
  • Change RAILS_GEM_VERSION to '3.2.15' in environment.rb
  • Run bundle update rails
  • Run the tests and see if everything still works
  • If not, reverse back to the old branch by doing git checkout master; optionally delete the new branch by doing git branch -D new_rails

Taken from this question: Site dead. "ACTION REQUIRED: Rails Security Vulnerability "

Community
  • 1
  • 1
Dennis Hackethal
  • 13,662
  • 12
  • 66
  • 115