Rails:没有要加载的文件 -- action_dispatch [英] Rails: no such file to load -- action_dispatch
问题描述
我无法启动我的服务器,这真的没有意义.跟踪路径,找到 gems,安装、卸载、重新安装,但似乎没有任何效果.通过 RVM 安装在 OS X 上.所以这是统计数据:$哪个红宝石/Users/Ross/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
I cannot start my server, it really doesn't make sense. Traced the paths, found the gems, install, uninstalled, re-installed, and nothing seems to work. Installed on OS X via RVM. So here's the stats: $ which ruby /Users/Ross/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
$ which rails
/Users/Ross/.rvm/gems/ruby-1.9.2-p180/bin/rails
$ which gem
/Users/Ross/.rvm/rubies/ruby-1.9.2-p180/bin/gem
$ gem list
*** LOCAL GEMS ***
actionmailer (3.1.3)
actionpack (3.1.3)
activemodel (3.1.3)
activerecord (3.1.3)
activeresource (3.1.3)
activesupport (3.1.3)
arel (2.2.1)
builder (3.0.0)
bundler (1.0.21)
erubis (2.7.0)
hike (1.2.1)
i18n (0.6.0)
json (1.6.4)
mail (2.3.0)
mime-types (1.17.2)
multi_json (1.0.4)
polyglot (0.3.3)
rack (1.3.6)
rack-cache (1.1)
rack-mount (0.8.3)
rack-ssl (1.3.2)
rack-test (0.6.1)
rails (3.1.3)
railties (3.1.3)
rake (0.9.2.2 ruby, 0.8.7)
rdoc (3.12)
rubygems-update (1.8.15)
sprockets (2.0.3)
thor (0.14.6)
tilt (1.3.3)
treetop (1.4.10)
tzinfo (0.3.31)
$ gem env
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.15
- RUBY VERSION: 1.9.2 (2011-02-18 patchlevel 180) [x86_64-darwin11.2.0]
- INSTALLATION DIRECTORY: /Users/Ross/.rvm/gems/ruby-1.9.2-p180
- RUBY EXECUTABLE: /Users/Ross/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
- EXECUTABLE DIRECTORY: /Users/Ross/.rvm/gems/ruby-1.9.2-p180/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-darwin-11
- GEM PATHS:
- /Users/Ross/.rvm/gems/ruby-1.9.2-p180
- /Users/Ross/.rvm/gems/ruby-1.9.2-p180@global
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/
更新 12/16/12-=>
Update 12/16/12-=>
宝石文件:
source 'http://rubygems.org'
require 'rubygems'
gem 'rails'
gem 'actionpack'
gem 'jquery-rails'
gem 'haml'
gem "devise", :git => "https://github.com/plataformatec/devise.git"
# gem 'oa-core'
gem 'omniauth'
gem 'omniauth-openid'
gem 'omniauth-twitter'
gem 'omniauth-facebook'
gem 'omniauth-github'
gem "settingslogic"
gem 'composite_primary_keys'
gem 'addressable'
gem 'faraday'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
gem 'pg'
gem 'squeel'
gem 'sqlite3'
gem 'mysql2', '~> 0.2.6'
gem "bcrypt-ruby", :require => "bcrypt"
group :development, :test do
gem 'rspec-rails'
gem 'ruby-debug19', :require => 'ruby-debug'
gem 'hpricot', :require => false #html2haml
gem 'ruby_parser', :require => false # html2haml
gem 'pickle'
gem 'awesome_print', :require => 'ap'
gem 'factory_girl_rails'
end
group :development do
gem 'heroku', :require => false
gem 'sass'
end
group :test do
gem 'shoulda'
gem 'cucumber-rails'
gem 'spork', '~> 0.9.0.rc3'
gem 'guard-spork'
gem 'database_cleaner'
end
推荐答案
是一个安全冲突;我不得不chown gems 目录中的所有文件.所有者是 root,除非我想 sudo 服务器,否则我只需要我的用户有权访问所有文件
was a security conflict; I had to chown all the file in the gems directory. The owner was root and unless I wanted to sudo the server, I just need my user to have rights to all the files
这篇关于Rails:没有要加载的文件 -- action_dispatch的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!