Project

General

Profile

[SOLVED BY SELF]Redmine or Ruby can't see rails

Added by Nikita Bogdanov almost 11 years ago

upd: Because i have redmine version 1.2.1 him required rails v2.3.11. Tnx to myself.

====
I tried to start redmine on FreeBSD (by fcgi) or on Linux, and have the same result.
On all systems i have this problem.
Google not help:(
Tnx
Some outputs:

===
#uname -r
9.1-RELEASE

===
#cat config/environment.rb | grep RAILS_GEM_VERSION
#RAILS_GEM_VERSION = '3.2.1' unless defined? RAILS_GEM_VERSION

===
#ruby script/server -e production
Missing the Rails gem. Please `gem install -v= rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.

===
#gem list

  • LOCAL GEMS ***

actionmailer (3.2.13, 3.2.1, 2.3.14)
actionpack (3.2.13, 3.2.1, 2.3.14)
activemodel (3.2.13, 3.2.1)
activerecord (3.2.13, 3.2.1, 2.3.14)
activerecord-postgresql-adapter (0.0.1)
activeresource (3.2.13, 3.2.1, 2.3.14)
activesupport (3.2.13, 3.2.1, 2.3.14)
arel (4.0.0, 3.0.2)
builder (3.2.2, 3.0.4)
bundler (1.3.5)
crash-watch (1.1.9)
daemon_controller (1.1.4)
erubis (2.7.0)
fcgi (0.9.1)
hike (1.2.3)
i18n (0.6.4, 0.6.1, 0.4.2)
iconv (1.0.3)
journey (1.0.4)
json (1.8.0)
mail (2.5.4, 2.4.4)
mime-types (1.23)
multi_json (1.7.7)
passenger (4.0.5)
pg (0.15.1)
polyglot (0.3.3)
rack (1.5.2, 1.4.5, 1.1.6)
rack-cache (1.2)
rack-ssl (1.3.3)
rack-test (0.6.2)
rails (3.2.13, 3.2.1, 2.3.14)
railties (3.2.13, 3.2.1)
rake (10.0.4)
rdoc (4.0.1, 3.12.2)
sprockets (2.2.2, 2.1.3)
thor (0.18.1, 0.14.6)
tilt (1.4.1)
treetop (1.4.14)
tzinfo (1.0.0, 0.3.37)

===
#gem environment
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.24
- RUBY VERSION: 1.8.7 (2012-10-12 patchlevel 371) [amd64-freebsd9]
- INSTALLATION DIRECTORY: /usr/local/lib/ruby/gems/1.8
- RUBY EXECUTABLE: /usr/local/bin/ruby18
- EXECUTABLE DIRECTORY: /usr/local/bin
- RUBYGEMS PLATFORMS:
- ruby
- amd64-freebsd-9
- GEM PATHS:
- /usr/local/lib/ruby/gems/1.8
- /root/.gem/ruby/1.8
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:

===
#gem sources * CURRENT SOURCES *

http://rubygems.org/

#gem install ri
ERROR: Could not find a valid gem 'ri' (>= 0) in any repository

=
Part From Apache

<VirtualHost >
ServerName myserv.medomain.myzone
FastCgiServer /usr/local/redmine/public/dispatch.fcgi -idle-timeout 120 -initial-env RAILS_ENV=production -i
DocumentRoot "/usr/local/redmine/public"
RailsEnv production
ErrorLog /var/log/redmine-error.log
CustomLog /var/log/redmine-custom.log combined
<Directory "/usr/local/redmine/public">
AddHandler fastcgi-script fcgi
Options +ExecCGI +FollowSymlinks
Order allow,deny
Allow from all
AllowOverride all
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.
)$ dispatch.fcgi
</Directory>
</VirtualHost>

From Apache error log:

Missing the Rails gem. Please `gem install -v= rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.
[Tue Jun 18 22:48:20 2013] [warn] FastCGI: server "/usr/local/redmine/public/dispatch.fcgi" (pid 41658) terminated by calling exit with status '1'