2
votes

I'm trying to get Ruby up and running but keep running into this problem. OS: Debian 6 Wheezy Ruby: 2.2.1 Rails: 4.2.6

Create a new project: Rails new Sample1

Get the famous "We're sorry page", error 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:inmap!' /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:inspecs' /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:inrequested_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:insetup' /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:inrequire' /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:inblock 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:inrun_load_path_setup_code' /usr/share/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'

I've been trying all day to get this going. I had no idea Ruby would be so tough just to get up and running.

2

2 Answers

2
votes

I just encountered this issue myself. As have others.

You could try installing the gem directly:

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

Then trying running Phusion Passenger again. If there is a similar error for another gem, it might mean that the gems were installed in a different location than Phusion Passenger is using.

For example, you might also need to install a newer version of mime-types:

gem install mime-types -v '3.0'

I don't have much experience with Phusion Passenger. Does it work with RVM? It might be worth using RVM if that is possible.

0
votes

Try running bundle install to make sure all dependencies are installed.

I got a similar error when running a dockerized ruby app locally - I forgot to re-build the app after adding new gems to the Gemfile.