代码之家  ›  专栏  ›  技术社区  ›  t56k

服务器上出现500内部服务器错误,在本地工作

  •  0
  • t56k  · 技术社区  · 11 年前

    当所有错误 production.log 给我的是这个吗?

    11:     <%= javascript_include_tag "application" %>
    12:     <%= csrf_meta_tags %>
    13:     <%= yield(:head) %>
    app/views/layouts/application.html.erb:10:in `_app_views_layouts_application_html_erb__4417234491726047977_45250520'
    app/controllers/docs_controller.rb:27:in `index'
    Processing by ErrorsController#broken as HTML
    Rendered errors/broken.html.erb within layouts/application (0.5ms)
    Completed 500 Internal Server Error in 16ms
    

    仅供参考:第10行 application.html.erb <%= stylesheet_link_tag "application", :media => "all" %> 所以我认为这与我的CSS或gemfile有关。我该如何进一步调查?

    此外,我的gemfile:

    source 'https://rubygems.org'
    
    gem 'rails', '3.2.12'
    gem 'json', '1.7.7'
    gem 'mysql2'
    
    group :assets do
      gem 'coffee-rails'
    end
    
    group :development do
      gem 'better_errors'
      gem 'binding_of_caller'
      gem 'meta_request'
    end
    
    group :development, :test do
      gem 'rspec-rails'
      gem 'steak'
      gem 'factory_girl_rails'
    end
    
    gem 'sass'
    gem 'less-rails'
    gem 'less-rails-bootstrap'
    gem 'jquery-rails'
    gem 'devise', '>= 2.1.2'
    gem 'cancan'
    gem 'paperclip', '~> 3.0'
    gem 'therubyracer'
    gem 'yaml_db'
    gem 'passenger'
    gem 'capistrano'
    gem 'prawn'
    gem 'bootstrap-wysihtml5-rails'
    gem 'turbolinks'
    gem 'jquery-turbolinks'
    gem 'kaminari'
    gem 'truncate_html'
    gem 'rails3-jquery-autocomplete'
    gem 'whenever'
    gem 'impressionist'
    gem 'acts_as_list'
    gem 'acts_as_indexed'
    gem 'state_machine'
    gem 'exception_notification'
    gem 'public_activity'
    
    1 回复  |  直到 9 年前
        1
  •  0
  •   t56k    11 年前

    需要我的gemfile uglifier ,它是与另一个gem的旧版本一起导入的。

    gem 'uglifier'
    

    修复它。