首页 文章

Ruby无法在任何来源中找到mime-types-data-3.2016.0221(Bundler :: GemNotFound)

提问于
浏览
1

我正在努力让Ruby运行起来但仍然遇到这个问题 . 操作系统:Debian 6 Wheezy Ruby:2.2.1 Rails:4.2.6

创建一个新项目:Rails new Sample1

获取着名的"We're sorry page",错误页面: Could not find mime-types-data-3.2016.0221 in any of the sources (Bundler::GemNotFound) /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/spec_set.rb:94:in block in materialize' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/spec_set.rb:87:in map!' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/spec_set.rb:87:in materialize' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/definition.rb:137:in specs'/var/lib/gems/1.9.1/gems/bundler-1.11 . 2 / lib / bundler / definition.rb:182:in specs_for' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/definition.rb:171:in requested_specs'/var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/environment.rb:18:in requested_specs' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/runtime.rb:13:in setup'/ var / lib / gems / 1.9.1 / gems / bundler-1.11.2 / lib / bundler.rb:92:in setup' /var/lib/gems/1.9.1/gems/bundler-1.11.2/lib/bundler/setup.rb:18:in '/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in require' /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in 在run_load_path_setup_code'/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:435:in running_bundler' /usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:296:in run_load_path_setup_code'/ usr / share中输入'/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:430:in activate_gem' /usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:297:in block /passenger/helper-scripts/rack-preloader.rb:100:in preload_app' /usr/share/passenger/helper-scripts/rack-preloader.rb:156:in '/usr/share/passenger/helper-scripts/rack-preloader.rb:30:in <module:PhusionPassenger>' /usr/share/passenger/helper-scripts/rack-preloader.rb:29:in '

我一直在努力让这一切顺利 . 我不知道Ruby只是为了起床和跑步而变得如此艰难 .

1 回答

  • 1

    我自己刚刚遇到过这个问题 . As have others .

    您可以尝试直接安装gem:

    gem install mime-types-data -v '3.2016.0221'
    

    然后再次尝试运行Phusion Passenger . 如果另一个宝石存在类似的错误,则可能意味着宝石安装在与Phusion Passenger正在使用的位置不同的位置 .

    例如,您可能还需要安装较新版本的 mime-types

    gem install mime-types -v '3.0'
    

    我对Phusion Passenger没有多少经验 . 它适用于RVM吗?如果可能的话,可能值得使用RVM .

相关问题