How can you obtain `heroku run rails --version` for a seeming Rails version mismatch?
Asked Answered
H

2

9

I've attempted several iterations of heroku run rails --version in order to ascertain the actual version number of the rails gem installed on an app stack on heroku. Nothing has returned success so far. For example, even running heroku run "rails --version" returns:

Running rails --version attached to terminal...  !   That feature is not available on this app's stack

Any ideas?

Ultimately the reason I ask is that I'm getting the following error:

can't activate rails (= 2.3.12, runtime), already activated rails-2.3.5. Make sure all dependencies are added to Gemfile.
/usr/ruby1.9.2/lib/ruby/gems/1.9.1/gems/bundler-1.0.7/lib/bundler/shared_helpers.rb:108:in `block in cripple_rubygems'

Which I'm not entirely following in that it would seem that there is a mismatch from what is actuallly in the Gemfile:

source :rubygems 
gem 'rails', '2.3.12'
# gem 'rails', '2.3.5' ## Was originally here, but I changed it to that above in hopes to resolve issue
gem 'i18n', '0.4.2' 
gem 'giternal' 
gem 'heroku' 

The source of this is an attempt to run ChiliProject on Heroku, which would be exceptionally useful. The original article is here if anyone would like to take a peak. It's a great replacement fork for Redmine.

Hooghly answered 27/7, 2011 at 18:18 Comment(0)
H
13

On the Heroku Cedar stack you can run heroku run bash --app appname and then vai the shell simply run rails --version which will return the version number.

Hooghly answered 23/11, 2011 at 3:37 Comment(1)
... and type exit to leave the shell.Armendariz
S
1

What version of ChiliProject? Our recent 2.0.0 version already has a Gemfile and is configured for Rails 2.3.12 out of the box. ChiliProject 1.x and Redmine are on older versions of Rails (2.3.5 and 2.3.11) and don't use Bundler at all.

Asking questions like this on the ChiliProject Forums will probably get you a better response in the future.

Soniferous answered 27/7, 2011 at 23:47 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.