First post here:
The error is below and i’m sure folks have posted it before, but perhaps
i’ve missed the solution:
I’m using apache because i first need to see if rails can work with
apache. Some particulars:
gem -v
0.8.11
ruby -v
ruby 1.8.4 (2005-12-24) [i686-linux]
rails -v
Rails 1.1.2
rails-1.1.2 is installed (via gem) and environment.rb’s
RAILS_GEM_VERSION=‘1.1.2’
In the browser:
Rails application failed to start properly.
The apache error log:
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] Cannot find gem
for Rails =1.1.2:
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] Install the
missing gem with ‘gem install -v=1.1.2 rails’, or
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] change
environment.rb to define RAILS_GEM_VERSION with your desired version.
Chris Crowley wrote:
First post here:
The error is below and i’m sure folks have posted it before, but perhaps
i’ve missed the solution:
I’m using apache because i first need to see if rails can work with
apache. Some particulars:
gem -v
0.8.11
ruby -v
ruby 1.8.4 (2005-12-24) [i686-linux]
rails -v
Rails 1.1.2
rails-1.1.2 is installed (via gem) and environment.rb’s
RAILS_GEM_VERSION=‘1.1.2’
In the browser:
Rails application failed to start properly.
The apache error log:
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] Cannot find gem
for Rails =1.1.2:
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] Install the
missing gem with ‘gem install -v=1.1.2 rails’, or
[Fri May 05 11:15:53 2006] [error] [client 127.0.0.1] change
environment.rb to define RAILS_GEM_VERSION with your desired version.
If you are under shared hosting this will help
check de boot.rb hack
http://wiki.onrails.com.ar/onrailscomarwiki/show/Instalacion+de+Rails+y+Gems+en+un+hosting+compartido
Pedro V.
http://blogs.onrails.com.ar
if you’re trying to setup your app on a host i assume that they don’t
got rails 1.1.2 yet? in that case the best thing to do is probaly freeze
rails.
just type
rake rails:freeze:gems
and you’re all set to go.
thanks for the responses (which i don’t have.) When i moved my gems,
into a gem directory within my ruby lib directory, things worked better.
I had installed rubygems in a separate branch of my home-dir, from the
ruby branch, also in my home dir. Unfortunately, I have deleted your
response re. the cache which seemed relevant. When i debugged this via
boot.rb, i recall it did lead to the return of an empty cache. When i
made the same call from within my own straight-ruby (ie. w/o the whole
apache mess) test program, i did get something back interestingly
enough. Sorry if this isn’t clear. Anyhow, i’m off to the next step,
which is FastCGI, then mysql, then postgresql.
This is what i had done, that didn’t work:
installed ruby:
|./configure --prefix=/home/chris
etc.
|
installed rubygems:
|export GEM_HOME=/home/chris/gems
ruby setup.rb config --prefix=/home/chris
etc.
|
and then of course i installed rails via rubygems.
The gems ended up in /home/chris/gems/gems/ ! Moving them to:
/home/chris/lib/ruby/gems/1.8/gems/
helped. I’ll play with my rubygems install next time (on the actual
production machine.)
chris.